php5

php developer tools

Possible Duplicate: Any good PHP IDE, preferably free or cheap? can anyone suggest good php developer tools to do the php scripting/coding easy. I dont know much about zend studio, is this a developer for php ...

Calling unexisting controller, how to generate exception?

Hello, I'm writing my own little MVC and I got a question... I'm passing $_SERVER['REQUEST_URI'] to the Router class which returns me controller, it's action and array of GET parameters. (For example Router said that I should call App_Controller->index()). So, I should create instance of App_Controller and call index() method. So, I'm ...

PHP cannot access object in array

in my application i get returned an array of objects and i am trying to access to access the object inside the array like this $array[0]->name but it doesn't work for some reason , i tried to access it like this - $var = $array[0]; $var->name and it shows me this error > Trying to get property of non-object whats going on here ? why i ...

How do i get the value from array and assign to view in zend frame work

iam executing a stored procedure in php and iam returning an array ["record"]=> array(1175) { [0]=> array(20) { ["Col1"]=> string(1) "Mode" ["col2"]=> string(16) "type" } } how do i get the col1 and col2 values from the array and assign it to the view .what should i ...

SOAP Error When Using GeoCoder

I have a webpage that uses Google Maps API to show a location of a business. It was previously working fine, but recently I noticed that the page now has a SOAP error: Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://geocoder.us/dist/eg/clients/GeoCoderPHP.wsdl' : failed ...

onkeyup Ajax Call and Live Search

I using a simple ajax script which returns found records using onkeyup in input field. The problem: Once a record has been returned from call it will stay printed on screen no matter what input is made or if string is latered on field. Sample: Lets say the string typed on form field is the word red. red gets printed to screen. if t...

How do I format the date and time That is received from database

Iam getting the date and time from Database as follows Date : 20100101(YYYY/MM/DD) Time : 120912 (HH:MM:SS) I have to format the Date as follows 20100101 --> (2010-10-11) (look to have ) "-" in between year and month and Day I have to format the time as follows 120912 --> 12:02:12 suppose I may have the time as 62367 from the d...

How to set our custom font and font size as default in TinyMCE?

How to set our custom font and font size as default in TinyMCE. Any body knows the solution please help me :( ...

formatting date string for html table

Can someone show me how to change this date stamp and print this in an html table? I have an input file with this time stamp format: 4-Start=20100901180002 This time format is stored like this in an array. I print out the array like so to create an html table: foreach ($data as $row){ $counter ++; ...

How to start with zend framework ?

Hi guys I would like to learn zend framework, I haven't done any projects in ZF. Could you please let me know some useful urls which explain how to start with ZF with a few examples Thank you guys ...

admininstration section

I'm building my first web application(i mean first huge web application)using php but i have some questions about admin section.what are the ways for making admin i mean i thought i could make it this way: First make an array: $pages = array('post' => 'posts.php', 'category' => 'categories.php'); And then read get var check if it's in...

How to read images from a folder with htaccess file

Hello, I am using the readfile function to read image files. It works in most cases except when an image is located in a directory with htaccess file. Here is an example: header("Content-type: image/jpeg"); ob_clean(); // clean output buffer flush(); // flush output buffer readfile("http://127.0.0.1/WebProjects/project1/data/media/im...

How to set session time out in PHP

Hi All, How can i set the session time out in PHP if the user stays inactive for a certain time in a web page or when the user close the browser tab. Please help me to solve this. ...

some intermediate images shows smaller in size

In php when I called echo image with the dynamics path it shows some images in small size and some in actual size. most time the intermediate images are shown small in browser <td align="center"> <?php $image_path = "components/com_mediaonline/uploads/uploads/" . $row["photo_id"] . "/thumb/" . $row["filename"]; ?> <a href="<?php echo...

virtumart in joomla

I have made a site site in joomla & in this i use Virtuemart. In virtumart when user purchse the item then there is a thank page. In this thank page i want to add one module which contain text so that user can change it later. But i am not be able to show it on thanks page. I want to show this module in thanks page data means in between...

Remove diacritics from a string

Is it possible? This is my input string: ľ š č ť ž ý á í é Č Á Ž Ý This is the output I want: l s c t z y a i e C A Z Y ...

php uploding file

hi i just want to know that if i am using move_uploaded_file function and use two argument first as the name of file and second as the destination. Normally i have uploaded many files with class uploader but now i want to give the destination as http://www.mydomain.com/testing/ Although i have given 777 permision to this folder but when...

x-httpd-php5s <-- s!

I'm trying to replicate a web-site on a test-server. However, on the test-server, .php files don't get interpreted. I found that the cause is a .htaccess file in the document root. Its contents: # Use PHP5 Single php.ini as default AddHandler application/x-httpd-php5s .php RewriteEngine On #RewriteRule ^$ index.php [QSA] RewriteRule ^(....

How do I select random values from an array in PHP?

I have an array of objects in PHP. I need to select 8 of them at random. My initial thought was to use array_rand(array_flip($my_array), 8) but that doesn't work, because the objects can't act as keys for an array. I know I could use shuffle, but I'm worried about performance as the array grows in size. Is that the best way, or is th...

CakePHP permissions management plugin

I'm specially looking for a good UI to manage permissions of users/groups based on CakePHP's auth and acl components. is anyone knows a good plugin (or good working code) to manage users and their permissions? ...