Daily Archives

Articles indexed Saturday June 5 2010

Page 19/79 | < Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >

  • update data after click tab

    - by alkitbi
    I want to add to this simple file ... When you click on a tab updated contents of the page or reload . <script type="text/javascript" src="yetii.js"></script> <script type="text/javascript" src="yetii-min.js"></script> <div class="Tabber"><div id="aldirazi"><ul id="aldirazi-nav"><li><a href="#UAEDES1">page1</a></li> </ul><div id="aldirazi-tabs"> <div class="tab" id="UAEDES1"> <? include("page1.php");?></div> </div> </div> </div> <script type="text/javascript"> var tabber1 = new Yetii({ id: 'aldirazi', persist: true }); </script>

    Read the article

  • PODS + WP Theme

    - by Sharath
    So I managed to setup pods and create my custom tables. Now I want to revamp my theme so that it pulls data from the POD table. Doesn't seem to be working... This is what I did.. I have a Pod called 'project_type' with a name (string) and a code (string) field. Have also added 3 entries via the admin system. I made a copy of the default wordpress plugin and renamed it to myTheme and activated it. Inside index.php of myTheme, I removed all the default code.. and have just the POD specific code as shown below. <?php echo "Hello World"; $p = new Pod('project_type'); echo $p->getTotalRows(); ?> However, when I reload my page, only Hello World shows up? A bit new to Wordpress so kindly advice.

    Read the article

  • Sortie de la version 2.5 de MorphOS, l'OS alternatif à l'AmigaOS

    [IMG]http://www.amigaimpact.org/modules/news/images/topics/morphos.gif[/IMG] Le système d'exploitation MorphOS, un OS léger et convivial descendant de feu AmigaOS est disponible aujourd'hui en version 2.5 sur matériel Apple, eMac, Mac mini G4, en plus des plateformes déjà supportées (Pegasos 1 & 2, carte EFIKA). La procédure d'enregistrement de MorphOS 2.5 est intégrée à la version de démonstration et consiste à :installer la version de démonstration librement téléchargeable utiliser l'outil RegTool pour s'enregistrer le paiement s'effectue à l'aide de PayPal Ces conditions d'utilisat...

    Read the article

  • Perl module for parsing natural language time duration specifications (similar to the "at" command)?

    - by Ryan Thompson
    I'm writing a perl script that takes a "duration" option, and I'd like to be able to specify this duration in a fairly flexible manner, as opposed to only taking a single unit (e.g. number of seconds). The UNIX at command implements this kind of behavior, by allowing specifications such as "now + 3 hours + 2 days". For my program, the "now" part is implied, so I just want to parse the stuff after the plus sign. (Note: the at command also parses exact date specifications, but I only want to parse durations.) Is there a perl module for parsing duration specifications like this? I don't need the exact syntax accepted by at, just any reasonable syntax for specifying time durations. Edit: Basically, I want something like DateTime::Format::Flexible for durations instead of dates.

    Read the article

  • What's a good way to set up a development environment on OS X for ruby, rails, and git?

    - by Ein2015
    I'm going to start development on a web app using ruby, rails, probably either postgres or mysql, and most likely apache. I'll be using a git repository with the master repo on another server. I've searched through stackoverflow and done some Googling... so here's what I have so far... What are your opinions on what's described on this page?: http://robots.thoughtbot.com/post/159805668/2009-rubyists-guide-to-a-mac-os-x-development What about this one?: http://www.buildingwebapps.com/articles/79197-setting-up-rails-on-leopard-mac I don't need helping finding an editor, there's plenty out there (TextMate, TextWrangler, MacVim), but I do need help to make sure I'm setting things up correctly to code, build, and run the web app from my mac. Here's a specific set of scenarios I could use some help on: Testing various versions of rails and/or ruby. Testing performance, vulnerabilities, monitoring queries, etc. Testing different versions of gems. Working on other projects on this same machine.

    Read the article

  • How do you use C++0x raw strings with GCC 4.5?

    - by Rob N
    This page says that GCC 4.5 has C++ raw string literals: http://gcc.gnu.org/projects/cxx0x.html But when I try to use the syntax from this page: http://www2.research.att.com/~bs/C++0xFAQ.html#raw-strings #include <iostream> #include <string> using namespace std; int main() { string s = R"[\w\\\w]"; } I get this error: /opt/local/bin/g++-mp-4.5 -std=gnu++0x -O3 rawstr.cc -o rawstr rawstr.cc:9:19: error: invalid character '\' in raw string delimiter rawstr.cc:9:5: error: stray 'R' in program What is the right syntax for raw strings?

    Read the article

  • Linq to SQL and Realtime Data

    - by Jeremy
    I have an application that needs to constantly (every 50ms), call to an MVC action, and pickup/drop off data. I am using Linq to SQL and MVC because of how simple they are to implement, and I know that they aren't perfect when it comes to performance, but it works relatively well, but the best speed I can get with my current approach is 200ms (without requests overlapping). Each call to the site will create a new instance of the datacontext, query/insert it and return that data. Is there a way to have the datacontext static, but submitchanges say every 5 seconds, so that i am pretty much hitting an in-memory version of the data?

    Read the article

  • Upload/Download images to FTP without bothering the user

    - by Dan B
    Hi, I know a lot of posts have been made in regards to FTP, but none have led me to what I need. I'm trying to upload a picture to a server (currently attempting FTP) but do it without notifying requiring the user to be involved. I want to be able to seamlessly upload/download the image when a certain user action occurs, but I don't want to use a third-party app like AndFTP. The idea is that a user will upload a picture, and then another user will be able to grab that picture based on which user put it up. No user will know where it's going or where it came from, nor will they navigate the FTP. Alternatively, does anyone have thoughts on a better way to do that? I thought of using the imgur api, but it can't be used commercially. It would, however, be perfect for my purposes. Is there a similar open-source alternative? Any help is greatly appreciated. Dan

    Read the article

  • ArrayBlockingQueue - How to "interrupt" a thread that is wating on .take() method

    - by bernhard
    I use an ArrayBlockingQueue in my code. Clients will wait untill an element becomes available: myBlockingQueue.take(); How can I "shutdown" my service in case no elements are present in the queue and the take() ist wating indefenitely for an element to become available? This method throws an InterruptedException. My question is, how can I "evoke" an Interrupted Exception so that take() will quit? (I also tought about notify(), but it seems I doesnt help here..) I know I could insert an special "EOF/QUIT" marker Element but is this really the only solution? UPDATE (regarding the comment, that points to another question with two solutions: one mentioned above using a "Poisoning Pill Object" and the second one is Thread.interrupt(): The myBlockingQueue.take() is used NOT in a Thread (extending Thread) but rather implements Runnable. It seems a Runnable does not provide the .interrupt() method? How could I interrupt the Runnable? Million Thanks Bernhard

    Read the article

  • SQL Server 2008 log issue

    - by George2
    Hello everyone, I am using SQL Server 2008 Enterprise. Under logs folder, in my machine it is C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\Log, there are three kinds of files, ERRORLOG, ERRORLOG.1, ERRORLOG.2 ... ERRORLOG.6; FDLAUNCHERRORLOG, FDLAUNCHERRORLOG.1, FDLAUNCHERRORLOG.2, ... FDLAUNCHERRORLOG.6; log_207.trc, log_208.trc, ... My question is what are the differnet function of such log files? And why there are files ends with .1, .2, etc? thanks in advance, George

    Read the article

  • how to run few vim commands in a raw

    - by temujin.ya.ru
    Hello. This is really noob question. There is set of vim commands : command1 : command2 etc., which I would neet to type in in a raw quite often. How to I make it automatic? It is simple regexp replace command set, however I cannot script those in sed, since it involves non-latin locales and for some reason vim handles non-latin regexps correctly, while sed not.

    Read the article

  • UITextField rigtht frame

    - by JustMe
    Hi, I have a peace of code like this: CGSize lSize = [@"Hello World" sizeWithFont:[UIFont fontWithName:@"Arial" size:13]]; Now I want to have the right frame to see this text in the UITextField. I don't want to change the font size just have the frame for UITextField to fit with this text. I will really appreciate any helps

    Read the article

  • fieldWithErrors not wrapping every error field

    - by Teef L
    Notice the following result when I submit blank :title and :description fields The validations are in the controller: class Question < ActiveRecord::Base validates_presence_of :title validates_presence_of :description And, the form is generated with those names: -form_for(@question) do |f| = f.error_messages = f.label :title = f.text_field :title, :size => 50, :onchange => remote_function(:url => {:action => :display_tag_suggestions}, :with => 'Form.Element.serialize(this)') #suggestions = f.label :description = f.text_area :description ... But, for some reason, only :title gets wrapped in the error div tags: <form action="/questions" class="new_question" id="new_question" method="post"> <div style="margin:0;padding:0"><input name="authenticity_token" type="hidden" value="6HQaiu1D0gBQcKw2pLeZP6Jvn0FSClPD5Sk9HwegzPg=" /></div> <div class="errorExplanation" id="errorExplanation"> <h2>2 errors prohibited this question from being saved</h2> <p>There were problems with the following fields:</p> <ul> <li>Title can't be blank</li> <li>Description can't be blank</li> </ul> </div> <label for="question_title">Title</label> <div class="fieldWithErrors"><input id="question_title" name="question[title]" onchange="new Ajax.Request('/questions/display_tag_suggestions', {asynchronous:true, evalScripts:true, parameters:Form.Element.serialize(this) + '&amp;authenticity_token=' + encodeURIComponent('6HQaiu1D0gBQcKw2pLeZP6Jvn0FSClPD5Sk9HwegzPg=')})" size="50" type="text" value="" /></div> <label for="question_description">Description</label> <textarea cols="40" id="question_description" name="question[description]" rows="20"></textarea> ... I don't think that behavior is expected. The problem most people have is that it's wrapping things with divs, which won't display properly. My problem is that fields aren't being wrapped with divs to begin with! I haven't made any (conscious) changes to how errors are handled, so I'm not sure why it's not working properly.

    Read the article

  • Switch Statement Case Evaluation?

    - by TheDarkIn1978
    i would like to have cases that evaluate the expression in my switch statement. is this not possible? switch (zSpeed) { case (zSpeed > zMax): this.zSpeed = zMax; break; case (zSpeed < 0): this.zSpeed = 0; break; default: this.zSpeed = zSpeed; }

    Read the article

  • Struct containing a Map in a Map? (C++/STL)

    - by karok
    I was wondering if it was possible to create a struct containing a number of variables and a map in a map. What I have at the moment: typedef std::map<std::string,double> lawVariables; struct ObjectCustomData { std::string objectType; bool global_lock; std::map<std::string, lawVariables> lawData; }; This struct is then passed on to another function as a single data block for that object. The structure setup is as follows: Each object has a data block that contains: its ObjectType, a bool for a lock, and a varying number of "laws" that could look like this: law1 -> var_a = 39.3; -> var_g = 8.1; law8 -> var_r = 83.1; -> var_y = 913.3; -> var_a = 9.81; Firstly, I'm unsure whether I should be using a Map within a Map and secondly even if this would be valid, I'm unsure how to fill it with data and how to recall it afterwards. I looked at maps because then I can search (on a name) if a certain object has a certain law, and if that law has certain variables. (sorry for the first messy post appearance, hope this is better :) )

    Read the article

  • Can't successfully run Sharepoint Foundation 2010 first time configuration

    - by Robert Koritnik
    I'm trying to run the non-GUI version of configuration wizard using power shell because I would like to set config and admin database names. GUI wizard doesn't give you all possible options for configuration. I run this command: New-SPConfigurationDatabase -DatabaseName "Sharepoint2010Config" -DatabaseServer "developer.pleiado.pri" -AdministrationContentDatabaseName "Sharepoint2010Admin" -DatabaseCredentials (Get-Credential) -Passphrase (ConvertTo-SecureString "%h4r3p0int" -AsPlainText -Force) Of course all these are in the same line. I've broken them down into separate lines to make it easier to read. When I run this command I get this error: New-SPConfigurationDatabase : Cannot connect to database master at SQL server a t developer.pleiado.pri. The database might not exist, or the current user does not have permission to connect to it. At line:1 char:28 + New-SPConfigurationDatabase <<<< -DatabaseName "Sharepoint2010Config" -Datab aseServer "developer.pleiado.pri" -AdministrationContentDatabaseName "Sharepoint 2010Admin" -DatabaseCredentials (Get-Credential) -Passphrase (ConvertTo-SecureS tring "%h4r3p0int" -AsPlainText -Force) + CategoryInfo : InvalidData: (Microsoft.Share...urationDatabase: SPCmdletNewSPConfigurationDatabase) [New-SPConfigurationDatabase], SPExcep tion + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletNewSPCon figurationDatabase I created two domain accounts: SPF_DATABASE - database account SPF_ADMIN - farm account I'm running powershell console as domain administrator. I've tried to run SQL Management studio as domain admin and created a dummy database and it worked wothout a problem. I'm running: Windows 7 x64 on the machine where Sharepoint Foundation 2010 should be installed and also has preinstalled SQL Server 2008 R2 Windows Server 2008 R2 Server Core is my domain controller I've installed Sharepoint according to MS guides http://msdn.microsoft.com/en-us/library/ee554869%28office.14%29.aspx installing all additional patches that are related to my configuration. Any ideas what should I do to make it work?

    Read the article

  • running an RMI server in command line and eclipse

    - by Noona
    I need to run my RMI server using the command line, my class files reside in this folder: C:\workspace\distributedhw2\AgencyServers\RmiEncodingServer\RmiServerClasses in package hw2.rmi.server The code base reside in this folder: C:\workspace\distributedhw2\AgencyServers\RmiEncodingServer\RmiServerCodeBase in package hw2.rmi.server I use the command line: java –classpath C:\workspace\distributedhw2\AgencyServers\RmiEncodingServer\RmiServerClasses\ -Djava.rmi.server.codebase=file:/C:\workspace\distributedhw2\AgencyServers\RmiEncodingServer\ Djava.security.policy=c:\HW2\permissions.policy hw2.rmi.server.RmiEncodingServer but I get a "class not found" exception as follows: Exception in thread "main" java.lang.NoClassDefFoundError: ûclasspath Caused by: java.lang.ClassNotFoundException: ûclasspath at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) Could not find the main class: GÇôclasspath. Program will exit. where have I gone wrong? also, if you can provide instructions on how to run the server in eclipse, I added the following as a VM argument, but I get a class not found exception to a class that is in the RmiServerCodeBase: -Djava.security.policy=C:\workspace\distributedhw2\permissions.policy -Djava.rmi.server.codebase=file:/C:\workspace\distributedhw2\AgencyServers\RmiEncodingServer thanks

    Read the article

  • How to deal with the limited Linq Support of OData (Open Data Protocol)

    - by user341127
    I have a software, which uses a lot of Linq to SQL. Recently, I want to immigrate to OData (or WCF Data Service) architecture. But I met too many problems in Linq for the Linq support of OData is so limited. I have to modify most of my Linq statements and test them thoroughly again. I am wondering whether there is a system way to solve such a problem instead of my manual work. For example, by an external package. BTW, now I have no confidence to use OData as a kind of architecture. You are appreciated to share your ideas. Thank you in advance, Ying

    Read the article

  • nonatomic property in model class when using NSOperationQueue (iPhone)?

    - by Andrew B.
    I have a custom model class with an NSMutableData ivar that will be accessed by custom NSOperation subclasses (using an NSOperationQueue). I think I can guarantee thread-safe access to the ivar from multiple NSOperations by using dependencies, and I can guarantee that I don't access the ivar from other code (say my main app thread) by waiting until the Q has finished all operations. Should I use a nonatomic property specification, or leave it atomic? Is there a significant impact on performance?

    Read the article

  • django accessing class variables in a view

    - by dana
    hello, i want to make a notification function, and i need fields from 2 different models. how can i access those fields? in my notification view i wrote this data = Notices.objects.filter(last_login<date_follow) where last_login belongs to the model class User , and date_follow to Follow but it is not a proper and correct way of accessing those variables. How can i access them? I need to compare the two dates for realising the notifications that one did not see since his last login. Thanks!

    Read the article

  • Can anybody explain the working of following code...?

    - by Siddhi
    Can anybody explain the working of following code...? interface myInterface{} public class Main { public static void main(String[] args) { System.out.println(new myInterface(){public String toString(){return "myInterfacetoString";}}); System.out.println(new myInterface(){public String myFunction(){return "myInterfacemyFunction";}}); } } Output is... myInterfacetoString primitivedemo.Main$2@9304b1 All answers saying that myInterface in println() statement is anonymous class. But as I already declared it as an interface, why does it allow me to create anonymous class of same name....? again...if these are anonymous classes then class main should allow me to give any name to these anonymous classes..But if try to do so..I'm getting compilation error

    Read the article

  • ASP.Net (C#) & MSQL -or- PHP & MySQL for Performance?

    - by Mike Curry
    Money, Staff, Skill and preference to open source or commercial is neutral. Lets take the best of the best programmers (for arguments sake) and think about this: What will perform better overall: PHP & MySQL or ASP.Net & Microsoft SQL (I don't want biased answers, just looking for Performance, and Speed).

    Read the article

  • Question about DBD::CSB Statement-Functions

    - by sid_com
    From the SQL::Statement::Functions documentation: Function syntax When using SQL::Statement/SQL::Parser directly to parse SQL, functions (either built-in or user-defined) may occur anywhere in a SQL statement that values, column names, table names, or predicates may occur. When using the modules through a DBD or in any other context in which the SQL is both parsed and executed, functions can occur in the same places except that they can not occur in the column selection clause of a SELECT statement that contains a FROM clause. # valid for both parsing and executing SELECT MyFunc(args); SELECT * FROM MyFunc(args); SELECT * FROM x WHERE MyFuncs(args); SELECT * FROM x WHERE y < MyFuncs(args); # valid only for parsing (won't work from a DBD) SELECT MyFunc(args) FROM x WHERE y; Reading this I would expect that the first SELECT-statement of my example shouldn't work and the second should but it is quite the contrary. #!/usr/bin/env perl use warnings; use strict; use 5.010; use DBI; open my $fh, '>', 'test.csv' or die $!; say $fh "id,name"; say $fh "1,Brown"; say $fh "2,Smith"; say $fh "7,Smith"; say $fh "8,Green"; close $fh; my $dbh = DBI->connect ( 'dbi:CSV:', undef, undef, { RaiseError => 1, f_ext => '.csv', }); my $table = 'test'; say "\nSELECT 1"; my $sth = $dbh->prepare ( "SELECT MAX( id ) FROM $table WHERE name LIKE 'Smith'" ); $sth->execute (); $sth->dump_results(); say "\nSELECT 2"; $sth = $dbh->prepare ( "SELECT * FROM $table WHERE id = MAX( id )" ); $sth->execute (); $sth->dump_results(); outputs: SELECT 1 '7' 1 rows SELECT 2 Unknown function 'MAX' at /usr/lib/perl5/site_perl/5.10.0/SQL/Parser.pm line 2893. DBD::CSV::db prepare failed: Unknown function 'MAX' at /usr/lib/perl5/site_perl/5.10.0/SQL/Parser.pm line 2894. [for Statement "SELECT * FROM test WHERE id = MAX( id )"] at ./so_3.pl line 30. DBD::CSV::db prepare failed: Unknown function 'MAX' at /usr/lib/perl5/site_perl/5.10.0/SQL/Parser.pm line 2894. [for Statement "SELECT * FROM test WHERE id = MAX( id )"] at ./so_3.pl line 30. Could someone explaine me this behavior?

    Read the article

< Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >