I am running a site on php with a mysql backend. Things have been fine but suddenly one users account started getting a 500 error. Each user has his own profile when they log into the any box so his internet explorer settings are the same no matter what box he logs on to. Does anyone know if this could be an internet explorer setting cau...
When I use Doctrine to generate classes from Yaml/db each Base class (which includes the table definition) extends the Doctrine_Record class.
Since my app uses a master and (multiple) slave db servers I need to be able to make the Base classes extend my custom record class to force writes to go to the master db server (as described here...
Hi All,
I have to parse an xml file with PHP to an object. At the moment I don't have a clue how to do this, help is appreciated.
The xml is quite big. I have to parse a part of it which looks like this:
<someNamespace:xmlDocument>
<someNamespace:categories>
<category name="Patrick" anAttribute="numericValue" anotherAttribute="numeri...
Can you recommend books to learn about PHP MVC please?
Thanks everyone.
...
Until now, I was debugging my PHP scripts and testcases using vim and the appropiate script with python backing it. However, me and my colleagues need to move forward and vim/gvim is not an option for them.
So I've tried to integrate debugging PHPUnit in Eclipse on my setup as an external tool, which again, works with vim. However, it s...
Hi,
I have a normal HTML select dropdown box
<select id="day" name="day">
<option value="0">All</option>
<option value="1">Mon</option>
<option value="2">Tue</option>
<option value="3">Wed</option>
<option value="4">Thu</option>
<option value="5">Fri</option>
</select>
But on occassion I want to make some options not clickable,...
The function below is designed to take an input hex (with or without the "#" prefix) and apply the color update to the portion of the image between startPixel and endPixel.
I can get the function to work fine on localhost tests when (1) supplying red, green, blue and (2) running the file directly as a stand alone (ie, just saving the co...
Is there a best practice for creating absolute URLs using the Zend framework? I wonder if there is some helper or if this would just be concatenating the scheme, host, etc. from the $_SERVER variable and then add the relative path generated by Zend.
...
I have a webpage which requires a login.
I am using curl to build the HTTP authentication request. It works, but I am not able to grab all the content from my links. I miss all the images.
How can I grab the images as well?
<?php
// create cURL resource
$URL = "http://10.123.22.38/nagios/nagvis/nagvis/index.php?map=Nagvis_CC";
//Ini...
I have following system setup
Windows XP Service pack 2
WAMP 2.0
PHP 5.3
I've configured my php.ini file with the following:
smtp=smtp.gmail.com
smtp_port=25;
and my PHP code is
<?php
mail('[email protected]','test subject','test body');
?>
The error I'm getting is
Warning: mail() [function.mail]: SMTP server respons...
I might be blind, but I don't see any good explanation here.
So, what does bindtextdomain do?
...
Currently I can not show site structure in the url IE www.site.com/parent-page/child-page without creating a subdirectory at the root. Is there an easy way to dynamically create the parent to child relationship other than creating subdirectories?
...
Greetings all!
Looking for some help with MVC in a PHP context. Currently I am building a small, lightweight MVC framework to help expedite application development at work. It's a long hard separation eliminating inline code - at least with numerous projects looming overhead and the temptation to utilize it ever-present.
I understand...
PHP has 2 closely related functions, escapeshellarg() and escapeshellcmd(). They both seem to do similar things, namely help make a string safer to use in system()/exec()/etc.
Which one should I use? I just want to be able to take some user input and run a command on it, and not have everything blow up. If PHP had an exec-type-function ...
This problem actually hit me recently.
So I was tasked with putting people's bios up on the web (asked for opinions in a different question), which I went with XML and just created elements based on what sections was going to be displayed.
Some people had formulas in their bio and when I was copying/pasting the formatting didn't copy o...
What does %2 do in the following php?
$id=(int)@$_REQUEST['id'];
echo ( !($id%2) )?
"{'id':$id,'success':1}":
"{'id':$id,'success':0,'error':'Could not delete subscriber'}";
...
i have built a web forum using php but i want to integrate it with videos that are uploaded such that people will be able to make comments on it in a tree view form... how do i integrate that to my php class.....any help with that?
...
Can this be done with regular expressions?
Examples
x-example-HEADER:teSt
becomes
x-example-header:teSt
y-exaMPLE:testoneTWOthree
becomes
y-example:testoneTWOthree
...
What do @ and (int) do in the following.
$id=(int)@$_REQUEST['id'];
...
I want to convert a Character to a 7 bit even parity. Can you please suggest me, how to implement this?
...