Search Results

Search found 932 results on 38 pages for 'patrick harrington'.

Page 23/38 | < Previous Page | 19 20 21 22 23 24 25 26 27 28 29 30  | Next Page >

  • triggering an event with jQuery live or delegate

    - by patrick
    I'd like to attach a handler to an element using either jQuery live() or delegate(). Looking at the docs I see I can attach the handler for a custom event. Is this possible for either of these jQuery functions to also trigger the handler? Basically I want to attach the handler function and run call it once. Thank you for any help.

    Read the article

  • Redis - which PHP module to use?

    - by Patrick
    If i check redis php supported language (http://code.google.com/p/redis/wiki/SupportedLanguages), there's 4 PHP ones: Redis PHP Bindings,phpredis,Predis,Redisent. Question is, which is the best and good to use? Thanks!

    Read the article

  • DRUPAL: JQuery Media module: flash video player doesn't work

    - by Patrick
    hi, I'm using JQuery Media module to integrate my own flash video player with Drupal website. I've tested everything on a local drupal installation and it works great. However I've updated an online drupal website and the player is not used. I can only see this message: "Use SwfTools Module to play FLV files if you only convert/upload FLV videos or FlowPlayer Module must be enabled in order to play FLV videos with other types." thanks

    Read the article

  • Excel vba: error hiding calculated field in Pivot table

    - by Patrick Honorez
    I have written several Subs to show/hide fields in a PivotTable. Now I am trying to do the same with a calculated field, but I get an error when hiding it. I took my code from the recorder and the recorder's code also halts on the last line. I googled the error message, without serious result. Sub PrRemove() 'remove PR Dim pt As PivotTable Set pt = ActiveSheet.PivotTables("MyPivot") pt.PivotFields("MyField").Orientation = xlHidden '<- here is the error End Sub The same code works fine if MyField is a normal field (not a calculated one). I am using Excel 2007 with SP2. Any clue ?

    Read the article

  • Losing session after Login - Java

    - by Patrick Villela
    I'm building an application that needs to login to a certain page and make a navigation. I can login, provided that the response contains a string that identifies it. But, when I navigate to the second page, I can't see the page as a logged user, only as anonymous. I'll provide my code. import java.net.*; import java.security.*; import java.security.cert.*; import javax.net.ssl.*; import java.io.*; import java.util.*; public class PostTest { static HttpsURLConnection conn = null; private static class DefaultTrustManager implements X509TrustManager { @Override public void checkClientTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {} @Override public void checkServerTrusted(X509Certificate[] arg0, String arg1) throws CertificateException {} @Override public X509Certificate[] getAcceptedIssuers() { return null; } } public static void main(String[] args) { try { SSLContext ctx = SSLContext.getInstance("TLS"); ctx.init(new KeyManager[0], new TrustManager[] {new DefaultTrustManager()}, new SecureRandom()); SSLContext.setDefault(ctx); String data = URLEncoder.encode("txtUserName", "UTF-8") + "=" + URLEncoder.encode(/*username*/, "UTF-8"); data += "&" + URLEncoder.encode("txtPassword", "UTF-8") + "=" + URLEncoder.encode(/*password*/", "UTF-8"); data += "&" + URLEncoder.encode("envia", "UTF-8") + "=" + URLEncoder.encode("1", "UTF-8"); connectToSSL(/*login url*/); conn.setDoOutput(true); OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream()); wr.write(data); wr.flush(); BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream())); String line; String resposta = ""; while((line = rd.readLine()) != null) { resposta += line + "\n"; } System.out.println("valid login -> " + resposta.contains(/*string that assures me I'm looged in*/)); connectToSSL(/*first navigation page*/); rd = new BufferedReader(new InputStreamReader(conn.getInputStream())); while((line = rd.readLine()) != null) { System.out.println(line); } } catch(Exception e) { e.printStackTrace(); } } private static void connectToSSL(String address) { try { URL url = new URL(address); conn = (HttpsURLConnection) url.openConnection(); conn.setHostnameVerifier(new HostnameVerifier() { @Override public boolean verify(String arg0, SSLSession arg1) { return true; } }); } catch(Exception ex) { ex.printStackTrace(); } } } Any further information, just ask. Thanks in advance.

    Read the article

  • Rails: include index with fields_for form helper

    - by Patrick Oscity
    i'm trying to build two models from one form by using the fields_for method. my code looks like this: <% for scale in @event.scales %> <% f.fields_for "scale[]", scale do |scale_form| %> <p> Scale<br /> <%= scale_form.label :name %> <%= scale_form.text_field :name %> <%= scale_form.label :price %> <%= scale_form.text_field :price %> </p> <% end %> <% end %> but unfortunately the output html is missing the id's of the scales: <p> Scale<br /> <label for="event_scale__name">Name</label> <input id="event_scale__name" name="event[scale][][name]" size="30" type="text" /> <label for="event_scale__price">Price</label> <input id="event_scale__price" name="event[scale][][price]" size="30" type="text" /> </p> ... here's the corresponding controller and model: class EventsController < ApplicationController ... def new @event = Event.new @providers = Provider.find(:all, :order => :name) 3.times { @event.scales.build } respond_to do |format| format.html end end ... end class Event < ActiveRecord::Base has_many :scales ... end what am i doing wrong?

    Read the article

  • PHP/codeigniter - use of exit()

    - by Patrick
    I have a few pages that require login, so all controllers that link to these pages start with $this->checkSession(); //...rest of the code CheckSession should verify the session is still live, otherwise display a message and stop the execution of the rest of the code in the controller: function checkSession() { if (!$this->session->userdata('is_logged_in')) { //the session has expired! $data['main'] = 'confirmation_message'; $data['title'] = "Session expired"; $this->load->vars($data); $this->load->view('template'); exit(); } } . I was expecting these instructions to happen in sequence, but I only get a blank page. How can I make sure exit() gets executed only after all views are loaded?

    Read the article

  • drupal: so many js and css files ?

    - by Patrick
    hi, I've realized I'm loading a lot of resources (24 css and 17 js files) using Drupal. I've several modules installed and they all come with a css and js file. For my website I'm only using 1 additional js plugin (all the other 16 come with Drupal modules). I've not installed useless modules. They are all necessary, and they require js such as swfobject, ajax_views, jquery.media, spamspan, lightbox (modal, video and default js files), etc Same thing with css files: ckeditor, filefield, lightbox, tagadelic, uploadfield, fieldgroup, vews, taxonomy_super_select, html-element, tabs, messages... etc For my website, I only use my theme css zen.css of course. So.. is this normal ? Or I should remove all this stuff? Are drupal websites normally heavy ? thanks

    Read the article

  • issue when outputting an http:// address in a sub-array with json and php

    - by Patrick
    Im trying to achieve an output like this {"status":"ok","0":{"id":"11","title":"digg","url":"http://www.digg.com"}} but instead i am getting this {"status":"ok","0":{"id":"11","title":"digg","url":"http:\/\/www.digg.com"}} this is the php code im using to generate the json $links = array('id'=>'11','title'=>'digg','url'=>"http://www.digg.com"); $msg = array('status'=>'ok',$links); echo json_encode($msg); any idea what is causing this?

    Read the article

  • EclipsePDT: how to add a Drupal project ?

    - by Patrick
    hi, how can I add an Eclipse project to my Eclipse PDT ? I've a Drupal installation on my hard-disk (a subfolder of Eclipse workspace). I've tried create new PHP project from eclipse, but it seems not to work. I've successively tried to import the Drupal project but Eclipse only recognize the SimplyModern project from drupal themes folder, and not the main Drupal project. thanks

    Read the article

  • HTML+CSS+Javascript: hi, I'm getting crazy with this

    - by Patrick
    hi, I'm getting crazy with some browsers fixes to do everytime I'm doing a new website. For example, lately I've built my own Flash Video Player and I lost hours to fix some problems such as aligning it in IE and Firefox and Safari. Would be so cool to have a intermediary layer, I could use to design my website, without taking care of all browsers fixes... I guess I'm a dreamer

    Read the article

  • very weird problem concerning date and time in silverlight + ria services

    - by Patrick LHM
    Hello Friends i'm facing a very weird problem in sliverlight 4 + RIA Services, or maybe it's not weird and i'm just a newbie anyway i hope someone here can help, the problem is the following i've created a function on the server side inside the domain service this function is very simple and has a line in it that adds the server current date and time to the database (it's an HR application and employees should sign in and out thrue it each from it's own pc ) Emp.TimeOut = system.DateTime.now (C# syntax) the weird part is that for some users it always adds 3 hours to the current time(exp if he signes out at 5 it shows 8) and for others it works perfectly. the server and all the stations in the company have exactly the same time settings and the same time zone, and anyway my fucntion is on the server side so it should no be realted to the users time. any ideas why this is happening ? i've bin trying to find out why for days now but with no luck

    Read the article

  • Drupal: CCK ImageField, multi-line description

    - by Patrick
    hi, I'm using CCK Image field (multi-images) and for each image I have the "Description" field, where I can add the image description. I was wondering if I can have multi-line description, instead of only one line. (Even using some specific symbol to go next line) thanks

    Read the article

  • Windows service Null ReferenceException

    - by Patrick
    I built a windows service on my local machine. when I install and run it locally it works perfectly fine. When I try to move it to my production machine I get a null reference exception error. I've created an installation package that also works perfectly fine on my machine, but when i run it on the production machine the service still fails. The service references a .dll that in turn has references to 3 other dlls. when i build the project it pulls all of the dlls into the debug folder for the project... I've even installed the service from that folder and it works localy on my machine. I know this has to have something to do with the references, but this is beyond me. Any tips/hints would be appreciated.

    Read the article

  • Drupal: how to apply plugins to modal lightbox content

    - by Patrick
    hi, I'm using a lightbox on a page of my website to display my nodes. I'm using some plugins such as an external simpletooltips plugin and the drupal plugin jQuery Media (to load flash video player for some video file-fields). All this stuff stop to work for the content of the lightbox, I guess because the content is not parsed... how can I solve this ? Should I trigger the plugins again ? Thanks

    Read the article

  • How can I call `update_attribute` for a list item in rails then actually update the html using jquery?

    - by Patrick Connor
    I want my users to be able to mark one or more items from an index view as "Active" or "Inactive" using a link. The text for the link should be state aware - so it might default to "Mark as Active" if the corresponding attribute was false or null, and "Mark as Inactive" if true. Once the user clicks the link and the attribute is updated in the controller, the link-text should update based on the new state. I am WAY off here, but this is a small sample of the code I have been trying... CONTROLLER ... respond_to :html, :js ... def update @item = Item.find(params[:id]) if @item.update_attributes(params[:item]) #Not sure of how to respond to .js here end end ... update.js.erb #how do I identify which element to update? $('#item[13456]').html("State aware text for link_to") VIEW - for item in @items = item.name = link_to "Mark as Active", item_path(item), :method => :put, :remote => true. :id => "item[#{item.id}]" I am happy to read any APIs, blogs, tutorials, etc. I just can't seem to get my hands/mind around this task. Any help or guidance is greatly appreciated!

    Read the article

  • Serialize Dictionary with a string key and List[] value to JSON

    - by Patrick
    How can I serialize a python Dictionary to JSON and pass back to javascript, which contains a string key, while the value is a List (i.e. []) if request.is_ajax() and request.method == 'GET': groupSet = GroupSet.objects.get(id=int(request.GET["groupSetId"])) groups = groupSet.groups.all() group_items = [] #list groups_and_items = {} #dictionary for group in groups: group_items.extend([group_item for group_item in group.group_items.all()]) #use group as Key name and group_items (LIST) as the value groups_and_items[group] = group_items data = serializers.serialize("json", groups_and_items) return HttpResponse(data, mimetype="application/json") the result: [{"pk": 5, "model": "myApp.group", "fields": {"name": "\u6fb4\u9584", "group_items": [13]}}] while the group_items should have many group_item and each group_item should have "name", rather than only the Id, in this case the Id is 13. I need to serialize the group name, as well as the group_item's Id and name as JSON and pass back to javascript. I am new to Python and Django, please advice me if you have a better way to do this, appreciate. Thank you so much. :)

    Read the article

  • Can someone explain this java interface to me please?

    - by Karl Patrick
    I realize that the method run must be declared because its declared in the runnable interface. But my question comes when this class runs how is the Thread object allowed if there is no import call to a particular package? how does runnable know anything about Thread or its methods? does the runnable interface extend the thread class? Obviously i dont understand interfaces very well. thanks in advance. class PrimeFinder implements Runnable{ public long target; public long prime; public boolean finished = false; public Thread runner; PrimeFinder(long inTarget){ target = inTarget; if(runner == null){ runner = new Thread(this); runner.start() } } public void run(){ } }

    Read the article

  • AppleScript Editor, write message to the "Result" window

    - by Patrick
    I am using the Mac OS X Apple Script Editor and (while debugging) instead of writing a lot of display dialog statements, I'd like to write the results of some calculation in the window below, called "Result" (I have the German UI here, so the translation is a guess). So is there a write/print statement that I can use for putting messages in the "standard out" window? I am not asking to put the messages in a logfile on the file system, it is purely temporary.

    Read the article

< Previous Page | 19 20 21 22 23 24 25 26 27 28 29 30  | Next Page >