Is it possible to run PHP Zend test cases (those that extend Zend_Test_PHPUnit_ControllerTestCase, etc.) through Eclipse PDT?
I would like to be able to run them in a similar fashion as you run JUnit tests in Eclipse, by right-clicking the test file and selecting "Run as a JUnit test case."
I'd love to see the green or red bar instead of having to go to the command line :).
Thanks in advance.
How can i run an cron job from php, and the cron to start in that moment?
I have a sitemap script, and i want to turn to a sitemap link, without waiting for him to do his job, to send information to call my job horn Sitemap.
Sorry my English
Hi,
i just want to know if there are any alternatives to simpleXML for parsing XML Data with PHP.
For example if simpleXML module is not loaded or even if there is a lib/class out there that has a better performance then SimpleXML.
Hi, anyone can help me with a preg_match? I'd like to use php's preg_match to determine if an input is a valid filename or not (only the filename + file extension, not the full path). General rules:
1) filename = a-z, A-Z, 0-9
2) extension = 3 or 4 letters
Thank you!
I setup the demo with a modified login I found called open-id selector. the login works fine and the identity url comes back, but the SREG data I ask for is never populated, required or optional. I am logging into my page with a gmail account. Here is the code from my try_auth.php that I edited
$sreg_request = Auth_OpenID_SRegRequest::build(
// Required
array('email'),
// Optional
array('fullname', 'gender', 'timezone', 'dob', 'country'));
what gives?
Hi, I'm just wondering how I could remove everything after a certain deliminator in PHP
ex:
Posted On April 6th By Some Dude
I'd like to have it so that it removes all the text including, and after, the deliminator "by"
Thanks
Hello
I'm looking to implement a system for tweeting directly from my site backend, which is written in PHP 5. I have a script from the internet that I can adapt, but I'm concerned that when Twitter switches to Oauth only, I'll be out in the cold.
Basically, I'm hoping someone can point me toward a script/tutorial that will let me do the following:
access twitter via the Oauth system
Post Tweets and receive error codes
Let me define an application/site name (I'm a bit fuzzy on whether Twitter allows this)
Ideally I need all 3 points explained in detail.
Thanks
Hello,
I'm using Twitter Basic authentification in a CRON agent to get et savelist of tweets in SQL db of 5 of my twitter account. Because we have to use Oauth after June 30th I'm searching to know how can I use oauth without connecting me manually. In fact I don't have user interface in my PHP file executed every 2 minutes.
Thanks in advance for your help.
Joel.
The user can enter a math problem like 5 + 654, 6 ^ 24, 2!, sqrt(543), log(54), sin 5, sin(50). After some reformatting (e.g. change sin 5 into sin(5)), and doing an eval, PHP gives me the right result. However, this is quite unsafe. Can anyone point me in the right direction parsing and solving a math question like the examples above, which is safe? Thanks.
Most of "multi-platform" CI tools I've seen are in the Java/.NET world, like TeamCity or Hudson. Is there a continuous integration tool that can handle both PHP and Rails projects?
Hi.
I'm looking for a jQuery Plugin to create a graph like that http://www.panic.com/blog/2010/03/the-panic-status-board/. To update the graph every x miliseconds from a PHP page and the numbers that are on the top. Is it possible?
Do you know any plugin that does that? Thanks!
I want to somehow round the numbers for a rating system in php like this:
4.6667 = 4.6
5.0001 = 5.1
is there any way to do that? (BTW i read the datas from a database)
I want to call crystal report in php.
now after searching i reach at that point that it is possible through COM object
but now one error is created which is
Fatal error: Call to undefined method com::OpenReport()
so how to remove it
Hello.
Can i ask a fundamental question. Why when I try to create a new mysqli object in php with invalid database infomation (say an incorrect database name) does it not return an error intstantly? I usually program server stuff in Java and something like this would throw back an error strait away, not after 20 seconds or so.
For example
$conn = new mysqli($host, $username, $password, $database);
Thanks!
Using PHP, what's the fastest way to convert a string like this: "123" to an integer?
Why is that particular method the fastest? What happens if it gets unexpected input, such as "hello" or an array?
i have the following url in a html page-
/delete/Release 1
But when i am trying to print it it comes in following manner-
/delete/Release%201
Can anyone suggest how to convert this hex value of %20 into a white space in PHP.
Yo.
I'm trying to find a way to insert a whole database structure into MySQL with PHP. Now, my main question is if there's any way to do this beyond just inserting the whole bloody thing line by line?
Thanks.
Ok, so I'm the author of a CMS and I'm interested in building a CalDAV-server that enables the user to interface with my CMS through CalDAV instead of only through the web, so they can see their calendars, add todos and things like that.
I've looked at http://www.davical.org/ which is a CalDAV service built in PHP, but it has its own database and I already have the DB stuff done and just want a middle-layer services that translates, both ways, to and from my databases using my functions.
Any ideas?
This below output come from php json_encode.What we see here is 0849 is twice.Since javascript only use sn to get value why we need the "0" value.The main problem is speed execution. If 800 kb data might can be reduce to 400 kb
{"success":"true","total":968,"data":[{"0":"0849","sn":"0849" }]
If no solution i have to make a script to filter in json_encode so no need twice data transter.
So I need to encode an array in PHP and store it in plain text in MySQL database, my question is should I use serialize() or json_encode()? What are the advantages and disadvantages of each of them?
I think either of them would do in this situation. But which one would you prefer and why? If it is for something other than an array?
I have some testcases/strings in this format:
o201_01_01a_Testing_to_see_If_this_testcases_passes:without_data
o201_01_01b_Testing_to_see_If_this_testcases_passes:data
rx01_01_03d_Testing_the_reconfiguration/Retest:
Actually this testcase name consists of the actual name and the description.
So, I want to split them like this :
o201_01_01a Testing_to_see_If_this_testcases_passes:without_data
o201_01_01b Testing_to_see_If_this_testcases_passes:data
rx01_01_03d Testing_the_reconfiguration/Retest:
I am unable to figure out the exact way to do this in explode in php
Can anyone help please?
Thanks.