I am a Java EE developer working mainly with JSPs, Servlets, and frameworks like Spring.
Will learning PHP be a wise decision ?
What would PHP offer me ?
I find myself drawn to the Parsing Expression Grammar formalism for describing domain specific languages, but so far the implementation code I've found has been written in languages like Java and Haskell that aren't web server friendly in the shared hosting environment that my organization has to live with.
Does anyone know of any PEG libraries or PackRat Parser Generators for Javascript or PHP? Of course code generators in any languages that can produce Javascript or PHP source code would do the trick.
I have a php array that has a bunch of data that I need but specifically I need just the name and longitude and latitude from each item in the array so that I can display points on a google map. The google map array needs to look like this in the end
var points = [
['test name', 37.331689, -122.030731, 4]
['test name 2', 37.331689, -122.030731, 4]
];
What is the best way to put my php data into a js array?
What I must to learn to write php web-site grabber (parser)?
It must collect information from other websites, such as as weather forecast, wiki "on this day", some news and other useful and interesting "every day" information!
what i must to read for writing m3u player on php?
sorry for my bad english
hello!
I'm trying to output multiline text with GD+PHP but can't get it working. my php knowledge is really basic.
here's the code, any idea on how to output 2 or 3 lines of text?
$theText = (isset($_GET['caption']))? stripslashes($_GET['caption']) :'';
imagettftext($baseImage, $textSize, $textAngle, $textXposition, $textYposition, $textColor, $fontName, $theText);
Hi,
We have discussion in my job place about question (We use 1 of the php frameworks):
Why program with php frameworks big web application if it can be done better with rubi on rails, python or java?
Please say our opinion
thanks
I'm wondering if this kind of thing will ever be possible in PHP (and whether it already is and I'm just missing something...)
<?php
function test() {
return array(
'id'=>10,
'name'=>'John'
);
}
echo 'Your name is: '.test()['name'];
?>
I'd really like to be able to use returned arrays directly instead of first assigning them to a var... possible?
What is the use of mysql_rollback() function in PHP?
How is it used?
please explain me with some example,
PS: Please Do not give me link to the php.net or, mysql site, I dont need AUTHOR language to understand it, I need the Developer way to understand...
I hope u understand...
Thanks in advance.
UPDATE
if i have Updated something in a tanle can i Reset the previous value using this function?
How can i write a program in php to get the domain information of an existing domain or a domain name is already taken..?? like informations using php?
I am somewhat new to PHP and I am wondering: How important is it to unset variables in PHP? I know in languages like C we free the allocated memory to prevent leaks, etc. By using unset on variables when I am done with them, will this significantly increase performance of my applications?
Also is there a benchmark anywhere that compares difference between using unset and not using unset?
The following PHP code will output 3.
function main() {
if (1) {
$i = 3;
}
echo $i;
}
main();
But the following C code will raise a compile error.
void main() {
if (1) {
int i = 3;
}
printf("%d", i);
}
So variables in PHP are not strictly block-scoped?
What is the easiest way to activate PHP and MySQL on Mac OS 10.6 (Snow Leopard)?
I'd prefer to use any built in versions before resorting to downloading from the PHP or MySQL websites.
I'm comfortable at the command line in Terminal.
I would like to be able to port some new site pages over to PHP using the same db as in the coldfusion site. Is it possible to have PHP run pages in say other directory and go back and forth ?
Many thanks for your reply.
Terry
PHP was the undisputed king of easy webapp development, until Ruby on Rails, Django, and other dynamic programming frameworks appeared. What are, in your opinion, PHP's strengths against the newcomers?
It gives me the following message:
The requested URL
/cgi-sys/php-cgiwrap/gcadmin/php5.cgi/projects/globalcolleage/index.php
was not found on this server.
Any suggestions?
(I'm using WAMP)
What are the differences between mod_php and cgi php script?
I mean, why it's better (is it?) to use mod_php instead simple php scripts, running them as CGIs?
Thanks
There is an epic lack of php CURL love on the internet for beginners like me. I was wondering how to use CURL to download & display an ICS file (They're plain text to me...) in my php code. Unless Fopen is 1,000 times easier, I'd like to stick with CURL for this one.
How to show progress bar in PHP where i have to upload the file size of of 100MB? I cannot have APC installed. I am allowed to do so..
Help me out to get it done...
We have PHP 5.2+
Hi, so I need the user to write a review about an article or book and send it to a DB via PHP but with some basic HTML formatting.. I mean, I have a form , when the user writes the review, the data is sent but without any kind of formatting, If the user want to write in a new line, the text is sent like plain text, I need to get also those new line breaks and simple stuff.
I know how to use PHP and DB connection, I just need to know how to get those new line breakes and stuff..
What is faster: writing PHP code using functions or writing it as pure script? So, as I see it Apache or any other server will create from PHP code using functions a pure script... I mean we had:
function foo($a, $b){ return ($a + $b); echo foo(4, 5)}
and Apache will turn it into something like:
echo (5 + 4)
Or will it?
My Question is suppose I have a form which needs validation through AJAX. The AJAX is sending data to to a file called do_ajax_validation.php Now should I put this file in 'include' folder and name it do_ajax_validation.inc.php and bar it from direct access of the user. Or shud i put it in the directory in which the original form resides??
I've been doing a lot of calculating stuff nowadays.Usually I prefer to do this job in PHP rather than Mysql though I know PHP is not good at this cuz I thought mysql may be worse.But I found some performance problem :some pages were loaded so slowly that 30 seconds' timelimit is not enough for them!So I wonder which is the better practice to do the calculations,and any princles for that?Suggestions would be appreciated.
Do any exist? Ideally it would also come with a library of basic PHP functions.
I have a bunch of simple PHP scripts (no extensions, no fancy dynamic hacks, etc) I'd like to convert to Java... It would be great if a tool could do 80% of the work while I do the other 20%.
I am sending an html email with php and it includes an image. Some email programs, such as gMail have a 'display images' button. The user has to click on that in order for the images in the email to show up.
Is there any way I can force email programs to show images that are sent within html emails generated by php?
I see i can get a MySQL database defined encoding in PHP using the function mysql_client_encoding(...), but is there a way to get a MySQL table defined encoding in PHP ?