php

how to retreive the last updated data from mulitple categories using php and mysql

Hi all, How to retreive the last updated data from mulitple categories using php and mysql. For example: Category Table: id categoryName 1 test1 2 test2 3 test3 Product Table id categoryId productName dateTime 1 1 product1 2010-05-06 10:00:37 2 1 product2 2010-05-06 10:10:41 3 2 product3 ...

How to use dojo-tree node in php query

Hi, could someone explain how it is possible to extract a node label (instead of a value) from a dojo-tree and than use it in a (php) query? Thank you! ...

How do I check if a user has the 'manage_options' capability in WordPress?

I'm trying to figure out if the current user can manage options. I'm using the following code: if (current_user_can('manage_options')) { add_filter('comments_array', 'myFunctionCall'); } But it produces this error (in WordPress 2.9.2, latest): Fatal error: Call to undefined function wp_get_current_user() in /Users/*/Sites/...

php array problem ..need expert

I have tried this in another post but trying my luck again. My current array that I am making produce a different result than I am wanting. I want to have this kind of out put Row: 0: Column: 1: ID 1 Row: 1: Column: 1: ID 1 Row: 0: Column: 2: ID 2 Row: 1: Column: 2: ID 2 Row: 2: Column: 2: ID 2 Row: 3: Column: 2: ID 2 ...

How to check whether user is login in web application?

I want to learn the whole details of web application authentication. So, I decided to write a CodeIgniter authentication library from scratch. Now, I have to make design decision about how to determine whether one user is login. Basically, after user input username & password pair. A cookie is set for this session, following navigations...

file array output printing

hi i am using an array of file, i mean input type ="file" to upload number of files at a time. i want to print or echo that file array values , how can i do this. please help me Thanks ...

How to sync two folders in PHP?

I am using windows, Mysql DB, PHP I am building the Joomla Component whose one of the functionality is to synchronize the folders I want to sync two folders of different name.. How can I do this? It has to be dne in the same machine, no two different servers are involved in it.. How to sync two folders in PHP? UPDATED IN Context of ...

how to convert html page to image using java or php

i want to know how to convert html file to image thanks and advance ...

How do I match number from 0 to 255 using regex in PHP?

/[0-9]+/ will also match those out of range,like 999 How to write an regex that matches exactly numbers between 0~255 ? ...

How to nest joins with CakePHP?

I'm trying to behave. So, instead of using following SQL syntax: select * from tableA INNER JOIN tableB on tableA.id = tableB.tableA_id LEFT OUTER JOIN ( tableC INNER JOIN tableD on tableC.tableD_id = tableD.id) on tableC.tableA_id = tableA.id I'd like to use the CakePHP model->find(). This will let me use the P...

PHP Sockets Errors (connection refused and No such file or directory)

Hello all, I am writing a server app (broadcaster) and a client (relayer). Several relayers can connect to the broadcaster at the same time, send information and the broadcaster will redirect the message to a matching relayer (for example relayer1 sends to broadcaster who sends to relayer43, relayer2 -> broadcaster -> relayer73...) ...

Can I RSA-encrypt in Java but decrypt in PHP?

Can I RSA-encrypt in J2ME or J2SE, and decrypt in PHP? I assume RSA is a specification, and has nothing to do with the languages. ...

PHP: How to add a logo with url link on a web player?

Hi all, I am doing a project in PHP in which Users can upload videos to the website.Visitors can watch the videos in the website. There will be a logo on the web player.when the visitor clicks on the logo it has to take him to a new page.I don't know how to add a logo with URL link on a web player. Please help me on this. Thanks in adv...

imagecreatefrompng error

<?php function LoadPNG($imgname) { /* Attempt to open */ $im = @imagecreatefrompng($imgname); /* See if it failed */ if(!$im) { /* Create a blank image */ $im = imagecreatetruecolor(150, 30); $bgc = imagecolorallocate($im, 255, 255, 255); $tc = imagecolorallocate($im, 0, 0, 0); ...

Best PHP timezone list

I have looked over the PHP list of supported timezones, but the whole list is a little long to include in a drop-down menu, for the user to select his or her timezone. Is there a list with the main city/area on that can be used? My geography is terrible and add that to not knowing all the area and which timezone they fall into it could...

Can phper give me some code snippet to consume the .net wcf service

Hi, I can successfully make a call to wcf from php without WCF message security enabled. I search the whole forum and cannot find any clue. I'd like to know how can I pass the credential ? My WCF service use the basichttpbinding on SSL with Message security enabled. Here is my code snippet to call my wcf from .NET ServiceReferen...

login using curl

After logging in using curl the css and javascript files are linking to localhost how to overcome this..... I have logged into external website using curl curl_setopt($ch, CURLOPT_URL,"https://externalwebsite.com"); after getting redirected to the external website the links in the external website are showing the localhost path for exam...

creating zip/rar/tar of folders in Joomla

Hi All, Please somebody help me. I want to compress a folder (which contains images & text files as well as few sub folders) in zip,rar,tar format & then give it for download to user. Is there any class/api/library/code to do so. I am working on Joomla CMS. Regards, Shahu. ...

How to sort MySQL query by two columns

The following is my DB data, how can I sorting it by sid and prev_sid with php/mysql!? sid prev_sid type 000 197 app_home 197 198 page_teach 198 218 page_teach 199 211 page_step 211 207 link 218 559 page_step 559 199 page_step Result: sid prev_sid typ...

<? echo $_Session['value'] ?> not working in Chrome

I have the following: <input type="hidden" name="phone_home" value="<? echo $_SESSION['full_home_phone'] ?>"> this works for firefox but not for google chrome.. can anyone help? thx ahead of time ...