php

How do I seamlessly authenticate users to use services associated with a Google Apps account?

Hi guys I'm building a Google Apps based solution. Basically I'm setting it up such that: When a Google Apps account holder installs it he/she enters the authentication details for a single Googles Apps account to be used - that account would be used by all users of the instance of the installed system for uploading to Google Docs asso...

Make a PHP GET request from a PHP script and exit

Hello all, Is there something simpler than the following. I am trying to make a GET request to a PHP script and then exit the current script. I think this is a job for CURL but is there something simpler as I don't want to really worry about enabling the CURL php extension? In addition, will the below start the PHP script and then j...

PHP:How to send the original password to the user when he clicks forgot password which is encrypted by using md5?

Hi all, I am using md5 to encrypt the passwords in my project. When user clicks on forgot password and submits his email,I have to send His password to him. But the password is encrypted using md5.Generating new password should not do.Because In this project admin can see all the details of the user. So i have to show the original pas...

Is there a way to optimise finding text items on a page (not regex)

After seeing several threads rubbishing the regexp method of finding a term to match within an HTML document, I've used the Simple HTML DOM PHP parser (http://simplehtmldom.sourceforge.net/) to get the bits of text I'm after, but I want to know if my code is optimal. It feels like I'm looping too many times. Is there a way to optimise th...

PHP:How can I send the Data entered by a user in a text field to a txt file?

In PHP How can I send the Data entered by a user in a text field to a txt file inside of a folder on my server. ...

PHP - error when insert date into MySQL

Hello everyone: I've got a typical problem when trying to insert a date into MySQL. The column defined in MySQL is of type DATE. My PHP version is 5.3.0 Apart from this date-related issue, the rest of my code works just fine. And this is my PHP script to do this: $tablename = BOOKS_TABLE; $insert = mysql_query("INSERT INTO $tabl...

What's the best way to implement news system without using wordpress ?

Hello, I'm a little afraid of using Wordpress because of his connotation "all made", plus my website is 100% hand coded, actually, i use the phpBB but it's not what I want cause visitors have to go out of the website to go to the forum to see the news. So how/what can I do to have my own news system management (publish/review/moderate ...

Get user IP via comment Form

I have inserted a hidden input in my comment form: $ip = $_SERVER['REMOTE_ADDR']; <input type="hidden" name="c-ip" value="<?php echo $ip; ?>"> Query : $cname = removeXSS(mysql_real_escape_string($_post['c-name'])); . . . $sql = "INSERT INTO guestbook (id, date, name, email, comment, ip, status) VALUES (' ', NOW(), '$cname', '$cemail'...

Active Directory on local server and intranet on external server.

I have a local Active Directory server and a external web server where my intranet is located. $ad = ldap_connect("ldap://ip-address") or die("Couldn't connect to AD!"); ldap_set_option($ad, LDAP_OPT_PROTOCOL_VERSION, 3); $bd = ldap_bind( $ad, "user@domain", "password") or die("Can't bind to server."); When I run this on a local web ...

[PHP] - Output buffer based progress bar

Hello people, I have been trying to get the following code working. It's a progress bar trick which uses ob_get_clean() function. Don't know why but this script just don't work! Only the initial percent - 1% comes up and nothing after that. <?php error_reporting(8191); function flush_buffers(){ @ob_end_flush(); @ob_f...

Intermittent Download Error from PHP web application over SSL with IE7 IE8

These are large (20-60mb) quickbooks files. Seemingly at random, IE users who are downloading them get "server returned an invalid or unrecognized response", and the download fails. Works 100% of the time in other browsers. This is over SSL. These downloads are being forced, I've tried every variation of headers I have seen. Currentl...

jQuery - Save to SQL via PHP

This is probably easy for you guys, but I can't understand it. I want to save the filename of an image to it's own row in the SQL base. Basically, I log on to the site where I have my own userID. And each user has its own column for background images. And the user can choose his own image if he wants to. So basically, when the user cli...

PHP: HOw to store and retrieve the data entered by a user in a text field from a file?

HI all, I want to Store the data entered by user in a file. If a user enters his description in a text field, Then i Have to store the data in a file. All the users data will go to the same file with their user name and description. And I have to retrieve The Data from that file for a particular user. For example if there are two us...

Can we only use the back-end of wordpress without any front-end ?

Hello, i just asked a question few minutes ago which led me to this one : I want to know if there is any chance to use only the back-end of wordpress ? I mean, link my admin interface to post news link my visitor interface on my website to the wordpress news so the visitor can access the news So the visitor never find out that i...

Kohana 3 - Blog like route "/post/YYYY/MM/DD/search-engine-optimized-url"

Hi Guys, I'm trying to create the above mentioned route... year, month, day and title should be passed to the method. Any idea how that works? Thanks in advance! ...

Facebook Status on website

http://stackoverflow.com/questions/383777/php-function-to-get-facebook-status I've got to step 5 but im stuck. How can I output these results in html format for say 10 status messages? Thanks, David ...

how to upload video in youtube using php without login

i hae my site and i want to upload video on you tube without login it is possibe.if yes how can do this ...

Anything in here that would escape string (PHP)

$_GET['search'] = ucfirst(strtolower(str_replace("_"," ",urldecode($_GET['search'])))); For some reason it's adding slashes into the string similar to mysqL_escape_string, anyone got any ideas what would be causing it? ...

retrieve only sub-pages (wordpress)

I want to list all sub-pages only one level though of one particular page. I was reading Function Reference/get pages and thought that $pages = get_pages( array( 'child_of' => $post->ID, 'parent' => $post->ID)) ; will do the trick but it is not working. It lists all pages on the same level like the page I call that code from. If I omit p...

jax-ws, authentication for php clents

Scenario: Server is glassfish with jax-ws web services and clients is php based What type of authentication for web services is more computable with php based clients ? HTTP Basic Authentication HTTPS Client Authentication Mutual Authentication (is it supported ?) Digest Authentication (is it supported ?) Description : Specifying ...