Search Results

Search found 7727 results on 310 pages for 'grails plugin'.

Page 26/310 | < Previous Page | 22 23 24 25 26 27 28 29 30 31 32 33  | Next Page >

  • Ajax / GroovyGrails Post data coming over with unexpected leading character. Who is encoding/decod

    - by ?????
    I'm having an encoding issue, and I'm not sure where to look for the problem. I have this Ajax.Request function (prototype library) sending data to a Groovy/Grails encoder var myAjax = new Ajax.Request(url, {method:'post', encoding:'UTF-8', contentType:'application/x-www-form-urlencoded', parameters:{'content':new_content}, onSuccess:success, onFailure:failure}); The data is coming in with an unexpected %A0 at the beginning: I have this simple controller that just echos the content back: def titlechange = { def content = URLDecoder.decode(params['content']) printf("Content: %s; DecodedContent = %s\n", params['content'], content) response.characterEncoding='UTF-8' render content } the debug print statement shows: Content: %A0Hello%2C%20world%21; DecodedContent = †Hello, world! Where is that %A0 coming from? My grails configuration has this: // The default codec used to encode data with ${} grails.views.default.codec="none" // none, html, base64 grails.views.gsp.encoding="UTF-8" grails.converters.encoding="UTF-8 Is the issue on the grails side or on the JavaScript side?

    Read the article

  • Grails unit testing domain classes with Set properties - is this safe?

    - by Ali G
    I've created a domain class in Grails like this: class MyObject { static hasMany = [tags: String] // Have to declare this here, as nullable constraint does not seem to be honoured Set tags = new HashSet() static constraints = { tags(nullable: false) } } Writing unit tests to check the size and content of the MyObject.tags property, I found I had to do the following: assertLength(x, myObject.tags as Object[]) assertEquals(new HashSet([...]), myObject.tags) To make the syntax nicer for writing the tests, I implemented the following methods: void assertEquals(List expected, Set actual) { assertEquals(new HashSet(expected), actual) } void assertLength(int expected, Set set) { assertLength(expected, set as Object[]) } I can now call the assertLength() and assertEquals() methods directly on an instance of Set, e.g. assertLength(x, myObject.tags) assertEquals([...], myObject.tags) I'm new to Groovy and Grails, so unaware how dangerous method overloading like this is. Is it safe? If so, I'm slightly* surprised that these methods (or similar) aren't already available - please let me know if they are. * I can see how these methods could also introduce ambiguity if people weren't expecting them. E.g. assertLength(1, set) always passes, no matter what the content of set

    Read the article

  • What makes Groovy+Grails a more productive setup than J2EE?

    - by Pradyumna
    I'm coming across references to 'Grails' and 'Groovy' quite often these days.. mostly on how great a productivity booster it is as opposed to standard J2EE, or things like JSF, Struts etc.. And there's also an impressive set of case studies in support of this on their web site too. So I just thought I would explore some of it.. As I start off on this, I was curious if there was any material (link, blog, article, paper..) that explains what are the special features in Grails+Groovy (and not found elsewhere, in the J2EE world) that makes it a more productive environment to work in? Thanks!

    Read the article

  • Error when installing plugin in Eclipse

    - by Derk
    When I try to install a plugin in Eclipse I get these error messages Registry event dispatcher Error notifying registry change listener. Error notifying registry change listener. Invalid registry object Error notifying registry change listener. Invalid registry object Error notifying registry change listener. Invalid registry object Error notifying registry change listener. Invalid registry object Error notifying registry change listener. Invalid registry object Has someone an idea what the cause of this problem could be? Thanks Edit: I see the Eclipse .log file has also a lot of new stack traces The first one is java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=nl_NL Framework arguments: -product org.eclipse.epp.package.jee.product Command-line arguments: -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.jee.product !ENTRY org.eclipse.equinox.registry 4 2 2010-05-06 21:04:31.236 !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.equinox.registry". !STACK 0 org.eclipse.core.runtime.InvalidRegistryObjectException: Invalid registry object at org.eclipse.core.internal.registry.TemporaryObjectManager.getObject(TemporaryObjectManager.java:98) at org.eclipse.core.internal.registry.BaseExtensionPointHandle.getExtensionPoint(BaseExtensionPointHandle.java:106) at org.eclipse.core.internal.registry.BaseExtensionPointHandle.getContributor(BaseExtensionPointHandle.java:45) at org.eclipse.core.internal.registry.BaseExtensionPointHandle.getNamespace(BaseExtensionPointHandle.java:37) at org.eclipse.ui.internal.PopupMenuExtender.registryChanged(PopupMenuExtender.java:520) at org.eclipse.core.internal.registry.ExtensionRegistry$2.run(ExtensionRegistry.java:921) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.core.internal.registry.ExtensionRegistry.processChangeEvent(ExtensionRegistry.java:919) at org.eclipse.core.runtime.spi.RegistryStrategy.processChangeEvent(RegistryStrategy.java:260) at org.eclipse.core.internal.registry.osgi.ExtensionEventDispatcherJob.run(ExtensionEventDispatcherJob.java:50) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

    Read the article

  • jQuery cycle plugin customizing

    - by spirax
    I'm using the jQuery Cycle plugin to start a slidshow of images when hovering over the initial image. This works fine. What I want after that is to have the slideshow stop when hovered off, and have a manual slideshow (next/prev buttons) start. This currently works, but the slideshow starts from the beginning each time it's initialized. I want it to begin at the current image that's loaded. I was playing around with getting the image's index from the DOM (as it's the only one with display:block) and using the option 'startingSlide' to resume it, but my index keeps returning as -1. jQuery('#home-menu li').hover(function() { setImages(jQuery(this).attr('title'), jQuery(this).find('.subtitle').text()); jQuery('#main .blog #projects .gallery .slideshow').cycle( { fx: 'scrollHorz', easing: 'easeOutBounce', speed: 2000, delay: 0 }); }, function() { // Before loading the images for the clickable slideshow, find the current image in the DOM array to use as the starting position slideshowStart = jQuery('.gallery .slideshow img:visible').index(this); console.log('Index: ' + slideshowStart); setImages(jQuery(this).attr('title'), jQuery(this).find('.subtitle').text()); jQuery('#main .blog #projects .gallery .slideshow').cycle('stop').cycle( { fx: 'scrollHorz', easing: 'easeOutBounce', startingSlide: slideshowStart, speed: 2000, timeout: 0, next: "#main .blog #projects .gallery span.span2", prev: "#main .blog #projects .gallery span.span1" }); }); setImages() just loads images into the DOM based on what li is being hovered over. Nothing special there. I want the image to be resumed when hovered over and hovered off. I've left out the resume part for hover on for the moment while I was trying to get it working - In case you were wondering.

    Read the article

  • realmethods plugin for eclipse

    - by user309944
    Hai friends I am trying to install realmethods plugin in eclipse. when i install realmethods it shows the following error Cannot complete the install because of a conflicting dependency. Software being installed: realMethods GAE Generator 1.0.0.201004110340 (aib_eclipse_feature.feature.group 1.0.0.201004110340) Software currently installed: Eclipse IDE for Java EE Developers 1.2.1.20090918-0703 (epp.package.jee 1.2.1.20090918-0703) Only one of the following can be installed at once: Common Navigator View 3.4.0.I20090525-2000 (org.eclipse.ui.navigator 3.4.0.I20090525-2000) Common Navigator View 3.4.2.M20100120-0800 (org.eclipse.ui.navigator 3.4.2.M20100120-0800) Common Navigator View 3.4.1.M20090911-1550 (org.eclipse.ui.navigator 3.4.1.M20090911-1550) Cannot satisfy dependency: From: realMethods GAE Generator 1.0.0.201004110340 (aib_eclipse_feature.feature.group 1.0.0.201004110340) To: org.eclipse.ui.navigator 3.4.2 Cannot satisfy dependency: From: Eclipse IDE for Java EE Developers 1.2.1.20090918-0703 (epp.package.jee 1.2.1.20090918-0703) To: org.eclipse.epp.package.jee.feature.feature.group [1.2.1.20090918-0703] Cannot satisfy dependency: From: Java EE IDE Feature 1.2.1.20090918-0703 (org.eclipse.epp.package.jee.feature.feature.group 1.2.1.20090918-0703) To: org.eclipse.platform.feature.group [3.5.1.R35x_v20090910-9gEeG1_FthkNDSP2odXdThaOu9GFDPn83DGB7] Cannot satisfy dependency: From: Eclipse Platform 3.5.1.R35x_v20090910-9gEeG1_FthkNDSP2odXdThaOu9GFDPn83DGB7 (org.eclipse.platform.feature.group 3.5.1.R35x_v20090910-9gEeG1_FthkNDSP2odXdThaOu9GFDPn83DGB7) To: org.eclipse.ui.navigator [3.4.1.M20090911-1550] what shall i do. can any one help me. thanks in advance

    Read the article

  • Jquery star rating plugin and cancel rating button

    - by Roger
    Using this plugin: http://www.fyneworks.com/jquery/star-rating/#tab-Testing I have a simple callback function that picks up the id from the radio buttons: <input type="radio" class="auto-submit-star {split:2}" id="myid" value="1" /> $('.auto-submit-star').rating({ callback: function(value, link){ alert($(this).attr('id')); } }); This works fine, but if the user clicks on the cancel button, then it can't read the id of it. In the js, I think the cancel button is added dynamically with: control.cancel = $('<div class="rating-cancel"><a title="' + control.cancel + '">' + control.cancelValue + '</a></div>') If I add an id to it like this: control.cancel = $('<div class="rating-cancel"><a id="someid" title="' + control.cancel + '">' + control.cancelValue + '</a></div>') How could I read the id? This would be undefined. I can set a class and use $('.myclass').attr('id') but I will have multiple ratings on one page so I'll need something similar to "this". Or is it possible for the cancel button to pick up the id of the corresponding radio buttons?

    Read the article

  • Using maven-release-plugin to tag and commit to non-origin

    - by Ali G
    When I do a release of my project, I want to share the source with a wider group of people than I normally do during development. The code is shared via a Git repository. To do this, I have used the following: remote public repository - released code is pushed here, every week or so (http://example.com/public) remote private repository - non-release code is pushed here, more than daily (http://example.com/private) In my local git repository, I have the following remotes defined: origin http://example.com/private public http://example.com/public I am currently trying to configure the maven-release-plugin to manage versioning of the builds, and to manage tagging and pushing of code to the public repository. In my pom.xml, I have listed the <scm/ as follows: <scm><connection>scm:git:http://example.com/public</connection></scm> (Removing this line will cause mvn release:prepare to fail) However, when calling mvn release:clean release:prepare release:perform Maven calls git push origin tagname rather than pushing to the URL specified in the POM. So the questions are: Best practice: Should I just be tagging and committing in my private repo (origin), and pushing to public manually? Can I make Maven push to the repository that I choose, rather than defaulting to origin? I felt this was implied by the requirement of the <connection/ element in <scm/.

    Read the article

  • Wordpress "Vote It Up" plugin help

    - by Sparks Memphis
    I'm creating a dig like site with wordpress, TDO Mini forms and Vote it up where people who live in the city can log on, post their ideas of how to improve the city and have others vote. on the home page there are 2 columns. right is the TDO submit form. left are the "Most Wanted" items. the posts with the highest rating. I've found an impressive lack of information on this plugin. im not great with php but i can make do most of the time. I want to output the post title, post author, links for yes and no votes as well as have the titles in the left column list in most popular order. preferably id like the home pages to have only the top 5 or so highest rated posts. I cant find any way to output that information as i need. I was really hoping there was a simple way to call the highest rated post titles in the loop for the main page but there doesnt seem to be a way. Bout the only thing i've found is the DisplayVotes tag which isnt incredibly helpful. does anybody know how i can accomplish this, or can provide some expert advise? help would be immensely appreciated.

    Read the article

  • jQuery validation plugin - removing elements

    - by d3020
    I'm using the jQuery validation plugin. On most of my input type... tags I have class='required'. When I submit the page, via JavaScript, the controls on the page that have this class are found. However, there are a handful of checkboxes that I don't need to validate. I've tried removing the class code completely from the input tag, also tried class='cancel', and class='required:false. When doing any of those things though when the form submits it can't find the checkbox control. How do I still keep the ability to do Request.Form and find my checkbox object but at the same time when the form submits don't apply validation to this particular control. Thank you. Edit here. This is what I'm using without the "checked" code and ternary operator. In my input tag I'm calling a function like this... sb.Append(" " + crlf); Inside that function is where I check for the True or False coming back, like this. case "chkFlashedCarton": strResultValue = pst.FlashedCarton.ToString(); if (strResultValue == "True") { strResultValue = " checked"; } break; strResultValue is what is returned back. Does this help to see? Thank you.

    Read the article

  • Installation failed for Scala eclipse plugin

    - by Ramesh Vel
    Hi, I am Scala newbie. Just started playing. Today i started to install scala plugin for eclipse (in ubuntu machine), but its failed everytime. Below the error message. An error occurred while collecting items to be installed session context was:(profile=PlatformProfile, phase=org.eclipse.equinox.internal.provisional.p2.engine.phases.Collect, operand=, action=). No repository found containing: osgi.bundle,ch.epfl.lamp.sdt.aspects,2.7.7.final No repository found containing: osgi.bundle,ch.epfl.lamp.sdt.core,2.7.7.final No repository found containing: org.eclipse.update.feature,ch.epfl.lamp.sdt,2.7.7.final No repository found containing: osgi.bundle,org.aspectj.runtime,1.6.4.20090304172355 No repository found containing: osgi.bundle,org.aspectj.weaver,1.6.4.20090304172355 No repository found containing: org.eclipse.update.feature,org.eclipse.contribution.weaving,1.6.4.20090313172428 No repository found containing: osgi.bundle,org.eclipse.contribution.weaving.jdt,1.6.4.20090313172428 No repository found containing: osgi.bundle,org.eclipse.equinox.weaving.aspectj,1.0.0.200902241436 No repository found containing: osgi.bundle,org.eclipse.equinox.weaving.hook,1.0.0.200902121956 No repository found containing: osgi.bundle,scala.library,2.7.7.final No repository found containing: osgi.bundle,scala.tools.nsc,2.7.7.final Can someone clarify me what was the problem. Cheer

    Read the article

  • Plugin architecture in C using libdl

    - by LukeN
    I've been toying around, writing a small IRC framework in C that I'm now going to expand with some core functionality - but beyond that, I'd like it to be extensible with plugins! Up until now, whenever I wrote something IRC related (and I wrote a lot, in about 6 different languages now... I'm on fire!) and actually went ahead to implement a plugin architecture, it was inside an interpreted language that had facilities for doing (read: abusing) so, like jamming a whole script file trough eval in Ruby (bad!). Now I want to abuse something in C! Basically there's three things I could do define a simple script language inside of my program use an existing one, embedding an interpreter use libdl to load *.so modules on runtime I'm fond of the third one and raather avoid the other two options if possible. Maybe I'm a masochist of some sort, but I think it could be both fun and useful for learning purposes. Logically thinking, the obvious "pain-chain" would be (lowest to highest) 2 - 1 - 3, for the simple reason that libdl is dealing with raw code that can (and will) explode in my face more often than not. So this question goes out to you, fellow users of stackoverflow, do you think libdl is up to this task, or even a realistic thought?

    Read the article

  • Eclipse Blackberry Preprocessor Not Working?

    - by Jessica
    I've already followed the directions @ http://stackoverflow.com/questions/1383277/using-preprocessor-directives-in-blackberry-jde-plugin-for-eclipse for making sure the blackberry plugin preprocessing hook is (theoretically) enabled. I'm using Eclipse 3.5.1 with Blackberry Plugin 1.1 with BB SDKs 4.7.0 and 4.6.0. I have my preprocessor defines set (and I've tried in both the Project's Blackberry Properties as well as the Workspace Blackberry Build settings), and checked their capitalization and spelling carefully too. I'm fairly confident the actual code to say "this stuff should be preprocessed" is good, because including/excluding preprocessed code seems to work fine on command line builds: //#preprocess --- at beginning of file and then code blocks like this throughout: //#ifndef jde_4_7 /* //#endif //#ifdef jde_4_7 import net.rim.device.api.ui.TouchEvent; //#endif //#ifndef jde_4_7 */ //#endif So what I can't figure out what else could be wrong that would cause Eclipse to not compile in my preprocessed code unless I remove the comments that are supposed to prevent the touch code from building into a build for blackberries that don't support touch. At one point it used to work (and no I haven't updated Eclipse), but sometime in the last couple of weeks it seemed to just stop working. And I'm getting kind of tired of the error-prone process of searching for ifdefs and manually commenting/uncommenting touch code and looking for a better solution while I do testing and initial development requiring testing both touch and non-touch functionality. Any other ideas on what could be wrong or how to fix it?

    Read the article

  • How can I install the BlackBerry v5.0.0 component pack into Eclipse?

    - by Dan J
    I'm trying to install the latest v5.0.0 "beta 2" BlackBerry OS Component Pack into Eclipse 3.4.2 with BlackBerry Eclipse plugin v1.0.0.67, but have hit a few problems. Has anybody found an easy way to do this? I had no trouble installing the v4.5.0 and v4.7.0 Component Packs. It's rather strange that BlackBerry are shipping new phones with the v5.0.0 OS installed (e.g. a Storm 2 9550 and Bold 9700 that I just bought), and pushing that update to phones whilst the BlackBerry website still considers the v5.0.0 SDK / Component Packs to be "beta 2"! If anybody knows when an official non-beta Component Pack is going to be released that might solve my problem... In case it helps, the problems I've hit so far are: -Contrary to the implication on the BlackBerry website, the Eclipse "Software Update..." option for the v5.0.0 Component Pack claims it only works on the v1.0.0 Eclipse BlackBerry plugin, not the new v1.1 one. -I then tried to install the v5.0.0 Component Pack through the "Software Updates..." menu in Eclipse using the v1.0.0 Eclipse BlackBery plugin. Once I'd done the 200MB download the install failed with a "Invalid zip file format" error. -I might just have been unlucky with a corrupted download but I did try it twice, once through "Software Updates..." and once by selecting "Archive" to install the downloaded Component Pack (which unlike v4.5.0 and v4.7.0 was a JAR, not a ZIP).

    Read the article

  • Need help with wp_rewrite in a WordPress Plugin

    - by Brad
    Ok, I've got this code that I've been using to spit out news to an application of mine. It was working until today. I've cutout all the logic in the following code to make it simpiler. But it should "WORK" Can someone help me fix this code to where it works, and is done right? I know it's hacked together ,but it didn't seem to have any problems until today. I have not updated anything, don't know what the deal is. Plugin Name: MyPlugin Example Version: 1.0.1 if ( ! class_exists("MyPlugin") ) { class MyPlugin { var $db_version = "1.0"; //not used yet function init() { //Nothing as of now. } function activate() { global $wp_rewrite; $this-flush_rewrite_rules(); } function pushoutput( $id ) { $output-out =' The output worked!'; $this-output( $output ); } function output( $output ) { ob_start(); ob_end_clean(); header( 'Cache-Control: no-cache, must-revalidate' ); header( 'Expires: Mon, 26 Jul 1997 05:00:00 GMT' ); header( 'Content-type: application/json' ); echo json_encode( $output ); //Must encode this... } function flush_rewrite_rules() { global $wp_rewrite; $wp_rewrite-flush_rules(); } function createRewriteRules( $rewrite ) { global $wp_rewrite; $new_rules = array( 'MyPlugin/(.+)' = 'index.php?MyPlugin=' . $wp_rewrite-preg_index(1) ); if ( ! is_array($wp_rewrite-rules) ) { $wp_rewrite-rules = array(); } $wp_rewrite-rules = $new_rules + $wp_rewrite-rules; return $wp_rewrite; } function add_query_vars( $qvars ) { $qvars[] = 'MyPlugin'; return $qvars; } function template_redirect_intercept() { global $wp_query; if ( $wp_query-get('MyPlugin') ) { $id = $wp_query-query_vars['MyPlugin']; $this-pushoutput( $id ); exit; } } } } if ( class_exists("MyPlugin") ) { $MyPluginCode = new MyPlugin(); } if ( isset($MyPluginCode) ) { register_activation_hook( __file__, array($MyPluginCode, 'activate') ); add_action( 'admin-init', array(&$MyPluginCode, 'flush_rewrite_rules') ); //add_action( 'init', array(&$MyPluginCode, 'init') ); add_action( 'generate_rewrite_rules', array(&$MyPluginCode, 'createRewriteRules') ); add_action( 'template_redirect', array(&$MyPluginCode, 'template_redirect_intercept') ); // add_filter( 'query_vars', array(&$MyPluginCode, 'add_query_vars') ); }

    Read the article

  • JQuery selfbuild plugin question - default value is overwritten.

    - by Bruno
    Hi jQuery ninjas. I need your help. I have made a really clean and simple example to illustrate my problem. I have build my own jquery plugin: (function($) { $.fn.setColorTest = function(options) { options = $.extend($.fn.setColorTest.defaults,options); return this.each(function() { $(this).css({ 'color': options.color}); }); } $.fn.setColorTest.defaults = { color: '#000' }; })(jQuery); As you can see I'm setting a default color and making it possible for the user to change it. My problem/question is: I have two paragraphs on the same page where I want to use the default color for the first and a different color for the second paragraph: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <title>Color Test</title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> <script type="text/javascript"> $(document).ready(function() { $('a#click').click(function() { $('#test1').setColorTest(); }); $('a#click2').click(function() { $('#test2').setColorTest({color: '#fff666'}); }); }); </script> </head> <body> <a id="click">click here</a> <a id="click2">click here2</a> <p id="test1">Test 1</p> <p id="test2">Test 2</p> </body> </html> My problem is that if I click on the second paragraph (p) that overrides the default color and afterwards clicks on the first p it will use the overwritten color and not the default color for the first p. How can I ensure that the first p always will use the default color? I know I can just define the color for the first p as well but that is not an option here $('#test1').setColorTest('color': '#000'); So what to do?

    Read the article

  • C# some sort of plugin system

    - by nLL
    Hi, I am a mobile web developer and trying to monetize my traffic with mobile ad services and i have a problem. First of all to get most of out of your ads you usually need to do server side request to advert company's servers and there are quite few ad services. Problem starts when you want to use them in one site. All have different approaches to server side calls and trying to maintain and implement those ad codes becomes pain after a while. So I decided to write a class system where i can simply create methods for every company and upload it to my site. So far i have public Advert class public AdPublisher class with GetAd method that returns an Advert public Adservice class that has Service names as enum I also have converted server request codes of all ad services i use to classes. It works ok but I want to be able to create an ad service class upload it so that asp.net app can import/recognize it automatically like a plugin system. As I am new to .net I have no idea where to start or how to do it. To make thing clear here are my classes namespace Mobile.Publisher { public class AdPublisher { public AdPublisher() { IsTest = false; } public bool IsTest { get; set; } public HttpRequest CurrentVisitorRequestInfo { get; set; } public Advert GetAd(AdService service) { Advert returnAd = new Advert(); returnAd.Success = true; if (this.CurrentVisitorRequestInfo == null) { throw new Exception("CurrentVisitorRequestInfo for AdPublisher not set!"); } if (service == null) { throw new Exception("AdService not set!"); } if (service.ServiceName == AdServices.Admob) { returnAd.ReturnedAd = AdmobAds("000000"); } return returnAd; } } public enum AdServices { Admob, ServiceB, ServiceC } public class Advert { public bool Success { get; set; } public string ReturnedAd { get; set; } } public partial class AdService { public AdServices ServiceName { get; set; } public string PublisherOrSiteId { get; set; } public string ZoneOrChannelId { get; set; } } private string AdmobAds(string publisherid) { //snip return "test" } } Basically i want to be able to add another ad service and code like private string AdmobAds(string publisherid){ } So that it can be imported and recognised as ad service. I hope i was clear enough

    Read the article

  • GPL vs plugin interfaces not designed with a specific application in mind

    - by Kristóf Marussy
    I am not seeking or in need of legal advice, but an interesting though experiment came to my mind. Imagine the following situtation (I cannot really think about a concrete example and I am unsure if a real manifestation even exists): there is a free (libre) api A licensed under some permissive license or even LGPL. Non-free application B implements this api in order host plugins, but there are other free software doing the same thing. Moreover, there is plugin C acting as a plugin under api A. It links to library D, that is under GPL, so C is also under GPL. Plugins using A are loaded into hosts via a dlopen-like mechanism and use complex data structure for host-plugin communication. Neither B nor C distribute any files that may be required for A to function properly (like headers containing the structure definitions of A or dynamic libraries containing helper functions for A written by the authors of A), but such things may exist. Now some user installs application B and plugin C on his machine, along with anything that may be required for api A to function properly. Then he proceeds and loads C into B and creates some intellectual property with B which is not a piece of software. Did a GPL violation happend at some point, and if so, who violated GPL and why? The authors of C violate D's license by making C possible to be used in non-free host B? This is a possibility because they can't give and exception of GPL (like one described in http://www.gnu.org/licenses/gpl-faq.html#GPLPluginsInNF or http://www.gnu.org/licenses/gpl-faq.html#LinkingOverControlledInterface) due to D's license terms. The authors of B violate C's and D's license by making C possible to be loaded in B? This is a possibility because http://www.gnu.org/licenses/gpl-faq.html#NFUseGPLPlugins disallows the mechanisms A uses for communitation between the free and non-free modules. The authors of A, because the api may be used (and in this case, was used) for communication between GPL'd and non-free software. This would be extremely absurd. The user, because at the moment of loading B into C, he made a derived work of C. I think this is impossible, because he does not distribute it. But would the situation change is he decided to release a configuration file of B which makes B load C as a plugin? Nobody, because A counts as a 'system library', and both B and C directly interact only with A, not eachother. In a sane world, this would happen... A concrete example of A could be some kind of audio (think LADSPA) or image processing api. However, I could find no such interface (that is free software, generic and is also implemented by commercial tools). A real-world example could also be quite enlightening.

    Read the article

  • Co-Authors Wordpress Plugin: coauthors_wp_list_authors function not working correctly

    - by rayne
    The Co-Authors Plus Plugin for Wordpress has a very annoying bug. The custom function coauthors_wp_list_authors lists authors the same way the wordpress function wp_list_authors does, but it does not include authors in the list who don't have a post of their own - if they have only entries in which they are listed as co-author but not as author, they will not be included in the list. That is of course missing a very important point. I've looked at the faulty SQL statement, but unfortunately my knowledge of advanced SQL, especially when it comes to JOINs, as well as my knowledge of the wp database structure is too limited and I remain clueless. There is a topic in the WP support forum, but unfortunately the information there is very outdated and the fix is not applicable anymore. I couldn't find any other, more current solutions on the internet. I'd be glad if somewhere here could help fix the SQL statement so it also lists co-authors who don't have posts where they're the sole author, as well as display the correct post count for all authors. Here's the entire function for reference purposes with a comment marking the SQL statement: function coauthors_wp_list_authors($args = '') { global $wpdb, $coauthors_plus; $defaults = array( 'optioncount' => false, 'exclude_admin' => true, 'show_fullname' => false, 'hide_empty' => true, 'feed' => '', 'feed_image' => '', 'feed_type' => '', 'echo' => true, 'style' => 'list', 'html' => true ); $r = wp_parse_args( $args, $defaults ); extract($r, EXTR_SKIP); $return = ''; $authors = $wpdb->get_results("SELECT ID, user_nicename from $wpdb->users " . ($exclude_admin ? "WHERE user_login <> 'admin' " : '') . "ORDER BY display_name"); $author_count = array(); # this is the SQL statement which doesn't work correctly: $query = "SELECT DISTINCT $wpdb->users.ID AS post_author, $wpdb->terms.name AS user_name, $wpdb->term_taxonomy.count AS count"; $query .= " FROM $wpdb->posts"; $query .= " INNER JOIN $wpdb->term_relationships ON ($wpdb->posts.ID = $wpdb->term_relationships.object_id)"; $query .= " INNER JOIN $wpdb->term_taxonomy ON ($wpdb->term_relationships.term_taxonomy_id = $wpdb->term_taxonomy.term_taxonomy_id)"; $query .= " INNER JOIN $wpdb->terms ON ($wpdb->term_taxonomy.term_id = $wpdb->terms.term_id)"; $query .= " INNER JOIN $wpdb->users ON ($wpdb->terms.name = $wpdb->users.user_login)"; $query .= " WHERE post_type = 'post' AND " . get_private_posts_cap_sql( 'post' ); $query .= " AND $wpdb->term_taxonomy.taxonomy = '$coauthors_plus->coauthor_taxonomy'"; $query .= " GROUP BY post_author"; foreach ((array) $wpdb->get_results($query) as $row) { $author_count[$row->post_author] = $row->count; } foreach ( (array) $authors as $author ) { $link = ''; $author = get_userdata( $author->ID ); $posts = (isset($author_count[$author->ID])) ? $author_count[$author->ID] : 0; $name = $author->display_name; if ( $show_fullname && ($author->first_name != '' && $author->last_name != '') ) $name = "$author->first_name $author->last_name"; if( !$html ) { if ( $posts == 0 ) { if ( ! $hide_empty ) $return .= $name . ', '; } else $return .= $name . ', '; continue; } if ( !($posts == 0 && $hide_empty) && 'list' == $style ) $return .= '<li>'; if ( $posts == 0 ) { if ( ! $hide_empty ) $link = $name; } else { $link = '<a href="' . get_author_posts_url($author->ID, $author->user_nicename) . '" title="' . esc_attr( sprintf(__("Posts by %s", 'co-authors-plus'), $author->display_name) ) . '">' . $name . '</a>'; if ( (! empty($feed_image)) || (! empty($feed)) ) { $link .= ' '; if (empty($feed_image)) $link .= '('; $link .= '<a href="' . get_author_feed_link($author->ID) . '"'; if ( !empty($feed) ) { $title = ' title="' . esc_attr($feed) . '"'; $alt = ' alt="' . esc_attr($feed) . '"'; $name = $feed; $link .= $title; } $link .= '>'; if ( !empty($feed_image) ) $link .= "<img src=\"" . esc_url($feed_image) . "\" style=\"border: none;\"$alt$title" . ' />'; else $link .= $name; $link .= '</a>'; if ( empty($feed_image) ) $link .= ')'; } if ( $optioncount ) $link .= ' ('. $posts . ')'; } if ( !($posts == 0 && $hide_empty) && 'list' == $style ) $return .= $link . '</li>'; else if ( ! $hide_empty ) $return .= $link . ', '; } $return = trim($return, ', '); if ( ! $echo ) return $return; echo $return; }

    Read the article

  • Google+ Platform Office Hours for April 11, 2012: Recent Activity jQuery Plugin

    Google+ Platform Office Hours for April 11, 2012: Recent Activity jQuery Plugin Here is the edited video from last week's Google+ platform office hours. Discuss this video on Google+: goo.gl This week we spent the first half of the show live coding a jQuery plugin that fetched recent public activity from a Google+ profile or page for inclusion on your website. Get the source code: goo.gl 1:15 - A demo of the implemented plugin 2:04 - The design of the plugin 2:57 - The coding begins! - Use the Google+ badge config tool to discover your userId (goo.gl or follow these instructions for pages: goo.gl Q&A 17:10 - Is there any kind of beta group that I can join for Google+? - Sign up for for the publisher preview group - goo.gl 19:03 - When will the API be available? 20:11 - When will there be more moderation tools for hangouts? 21:36 - How do I get Hangouts on air? 22:18 - An update on last week's report of Google Analytics social actions not agreeing with the +1 button count 25:53 - How do I join the hangout for these office hours? 26:44 - Using the activities search API is there any way to only see new activities? 28:18 - An announcement about our future office hours schedule From: GoogleDevelopers Views: 3387 47 ratings Time: 29:29 More in Science & Technology

    Read the article

  • Presentation Plugin for NetBeans IDE 7.2

    - by Geertjan
    I got some excellent help from Mark Stephens, who is from IDR Solutions, which produces JPedal. Using the LGPL version of JPedal, and code provided by Mark, it's now possible to right-click the node that appears in the Presentation Window: ...after which, using a file browser (to locate a file on disk) or a URL (a very simple check is done, the URL must start with "http" and end with "pdf"), you can now open PDF files as images (thanks to conversion from PDF to images done by JPedal) into NetBeans IDE, typically (I imagine) for presentation purposes: Note that you should consider the plugin in "alpha" state. But, despite that, I've had good results. Try it and use the URL below, as a control test (since it works fine for me), which produces the result shown above: http://edu.netbeans.org/contrib/slides/netbeans-platform/presentation-4-actions.pdf  However, for some PDFs, the plugin doesn't work, and I don't know why yet (trying to figure it out with Mark), resulting in this stack trace: java.lang.ArrayIndexOutOfBoundsException: 8 at org.jpedal.objects.acroforms.formData.SwingData.completeField(Unknown Source) at org.jpedal.objects.acroforms.rendering.DefaultAcroRenderer.createField(Unknown Source) at org.jpedal.objects.acroforms.rendering.DefaultAcroRenderer.createDisplayComponentsForPage(Unknown Source) at org.jpedal.PDFtoImageConvertor.convert(Unknown Source) at org.jpedal.PdfDecoder.getPageAsImage(Unknown Source) at org.jpedal.PdfDecoder.getPageAsImage(Unknown Source) Here's the location of the plugin, install it into NetBeans IDE 7.2; feedback is very welcome: http://plugins.netbeans.org/plugin/44525

    Read the article

  • Installing Chrome Java Plugin

    - by kyleskool
    I've been trying to install the Java plugin for Chrome for a couple hours now, and I figured it was time to ask people with more experience. I can't seem to get it working. My current Java version is the 64-bit OpenJDK 1.6.0_24. I tried installing the IcedTea plugin to no avail. I have Ubuntu 12.04 64-bit installed at the moment. When I tried testing if java was enabled in Chrome, any website with a Java applet would not load (when I disabled the plugin, they loaded, but not the applet). I followed the instructions from here: http://technonstop.com/install-java-plugin-ubuntu-linux which said to create this script and run it: JAVA_HOME=/usr/lib/jvm/jdk1.7.0 MOZILLA_HOME=~/.mozilla mkdir $MOZILLA_HOME/plugins ln -s $JAVA_HOME/jre/lib/i386/libnpjp2.so $MOZILLA_HOME/plugins Note: You may need to change the value of JAVA_HOME so that it correctly points to your installation of the JDK. 64-bit users will need to change the final line to: ln -s $JAVA_HOME/jre/lib/amd64/libnpjp2.so $MOZILLA_HOME/plugins but this did not work as well. I just test it in Firefox and it's working. Still nothing for Chrome

    Read the article

  • Maven2 - problem with pluginManagement and parent-child relationship

    - by Newtopian
    from maven documentation pluginManagement: is an element that is seen along side plugins. Plugin Management contains plugin elements in much the same way, except that rather than configuring plugin information for this particular project build, it is intended to configure project builds that inherit from this one. However, this only configures plugins that are actually referenced within the plugins element in the children. The children have every right to override pluginManagement definitions. Now : if I have this in my parent POM <build> <pluginManagement> <plugins> <plugin> <artifactId>maven-dependency-plugin</artifactId> <version>2.0</version> <executions> Some stuff for the children </execution> </executions> </plugin> </plugins> </pluginManagement> </build> and I run mvn help:effective-pom on the parent project I get what I want, namely the plugins part directly under build (the one doing the work) remains empty. Now if I do the following : <build> <pluginManagement> <plugins> <plugin> <artifactId>maven-dependency-plugin</artifactId> <version>2.0</version> <executions> Some stuff for the children </execution> </executions> </plugin> </plugins> </pluginManagement> <plugins> <plugin> <artifactId>maven-compiler-plugin</artifactId> <version>2.0.2</version> <inherited>true</inherited> <configuration> <source>1.6</source> <target>1.6</target> </configuration> </plugin> </plugins> </build> mvn help:effective-pom I get again just what I want, the plugins contains just what is declared and the pluginManagement section is ignored. BUT changing with the following <build> <pluginManagement> <plugins> <plugin> <artifactId>maven-dependency-plugin</artifactId> <version>2.0</version> <executions> Some stuff for the children </execution> </executions> </plugin> </plugins> </pluginManagement> <plugins> <plugin> <artifactId>maven-dependency-plugin</artifactId> <version>2.0</version> <inherited>false</inherited> <!-- this perticular config is NOT for kids... for parent only --> <executions> some stuff for adults only </execution> </executions> </plugin> </plugins> </build> and running mvn help:effective-pom the stuff from pluginManagement section is added on top of what is declared already. as such : <build> <pluginManagement> ... </pluginManagement> <plugins> <plugin> <artifactId>maven-dependency-plugin</artifactId> <version>2.0</version> <inherited>false</inherited> <!-- this perticular config is NOT for kids... for parent only --> <executions> Some stuff for the children </execution> <executions> some stuff for adults only </execution> </executions> </plugin> </plugins> </build> Is there a way to exclude the part for children from the parent pom's section ? In effect what I want is for the pluginManagement to behave exactly as the documentation states, that is I want it to apply for children only but not for the project in which it is declared. As a corrolary, is there a way I can override the parts from the pluginManagement by declaring the plugin in the normal build section of a project ? whatever I try I get that the section is added to executions but I cannot override one that exists already. EDIT: I never did find an acceptable solution for this and as such the issue remains open. Closest solution was offered below and is currently the accepted solution for this question until something better comes up. Right now there are three ways to achieve the desired result (modulate plugin behaviour depending on where in the inheritance hierarchy the current POM is): 1 - using profiles, it will work but you must beware that profiles are not inherited, which is somewhat counter intuitive. They are (if activated) applied to the POM where declared and then this generated POM is propagated down. As such the only way to activate the profile for child POM is specifically on the command line (least I did not find another way). Property, file and other means of activation fail to activate the POM because the trigger is not in the POM where the profile is declared. 2 - (this is what I ended up doing) Declare the plugin as not inherited in the parent and re-declare (copy-paste) the tidbit in every child where it is wanted. Not ideal but it is simple and it works. 3 - Split the aggregation nature and parent nature of the parent POM. Then since the part that only applies to the parent is in a different project it is now possible to use pluginManagement as firstly intended. However this means that a new artificial project must be created that does not contribute to the end product but only serves the could system. This is clear case of conceptual bleed. Also this only applies to my specific and is hard to generalize, so I abandoned efforts to try and make this work in favor of the not-pretty but more contained cut and paste patch described in 2. If anyone coming across this question has a better solution either because of my lack of knowledge of Maven or because the tool evolved to allow this please post the solution here for future reference. Thank you all for your help :-)

    Read the article

  • Does overloading Grails static 'mapping' property to bolt on database objects violate DRY?

    - by mikesalera
    Does Grails static 'mapping' property in Domain classes violate DRY? Let's take a look at the canonical domain class: class Book {      Long id      String title      String isbn      Date published      Author author      static mapping = {             id generator:'hilo', params:[table:'hi_value',column:'next_value',max_lo:100]      } } or: class Book { ...         static mapping = {             id( generator:'sequence', params:[sequence_name: "book_seq"] )     } } And let us say, continuing this thought, that I have my Grails application working with HSQLDB or MySQL, but the IT department says I must use a commercial software package (written by a large corp in Redwood Shores, Calif.). Does this change make my web application nobbled in development and test environments? MySQL supports autoincrement on a primary key column but does support sequence objects, for example. Is there a cleaner way to implement this sort of 'only when in production mode' without loading up the domain class?

    Read the article

< Previous Page | 22 23 24 25 26 27 28 29 30 31 32 33  | Next Page >