Search found 92 matches

by Suhoij
Thu Jun 16, 2011 9:32 am
Forum: PHP coding => General
Topic: PHP cURL Login Help
Replies: 10
Views: 2524

Re: PHP cURL Login Help

You don't need something specific to redirect. FOLLOW_LOCATION do it for you. Maybe if redirect comes with javascript on new page. Have you some test account to check it ?
by Suhoij
Thu Jun 16, 2011 9:14 am
Forum: PHP coding => General
Topic: PHP cURL Login Help
Replies: 10
Views: 2524

Re: PHP cURL Login Help

Instead http://www.provada.com/api/cookie.txt it must be full path to the file on server like '/var/www/provada.com/cookie,txt'
by Suhoij
Thu Jun 16, 2011 7:20 am
Forum: PHP coding => General
Topic: php post
Replies: 19
Views: 3011

Re: php post

You can use the session - just name the key in $_SESSION array unique. For ex 'data'
by Suhoij
Thu Jun 16, 2011 6:39 am
Forum: PHP coding => General
Topic: URL Rewritecode for seo purpose
Replies: 1
Views: 857

Re: URL Rewritecode for seo purpose

I think he wants mod_rewrite rules. Try to write them yourself and if you can't post here what you have.
by Suhoij
Thu Jun 16, 2011 6:37 am
Forum: PHP coding => General
Topic: php post
Replies: 19
Views: 3011

Re: php post

Don't use POST it is not right in this situation. It is better to save variables in session.
Write this on first page:

Code: Select all

$data = serialize( array( 'variable' => 'value' )  );
$_SESSION['data'] = $data;
and this on second

Code: Select all

$data = unserialize( $_SESSION['data'] );
echo $data['variable'];
by Suhoij
Thu Jun 16, 2011 6:18 am
Forum: PHP coding => General
Topic: php post
Replies: 19
Views: 3011

Re: php post

Is both pages on one server ?
by Suhoij
Thu Jun 16, 2011 6:01 am
Forum: PHP & MySQL Security
Topic: Is this code genuine or a hack??
Replies: 2
Views: 2322

Re: Is this code genuine or a hack??

This is the virus. It's generate javascript iframe. You can look at the code - write echo instead of eval.
by Suhoij
Thu Jun 16, 2011 5:57 am
Forum: PHP coding => General
Topic: php post
Replies: 19
Views: 3011

Re: php post

As I understand you need session mechanism. If redirects make auto - just put the params into session and clean session after redirecting on second page.
by Suhoij
Thu Jun 16, 2011 4:57 am
Forum: PEAR and PECL
Topic: MongoDB and PHP
Replies: 1
Views: 4310

Re: MongoDB and PHP

So mongo db info is not shown in phpinfo? Did you add the extension string to correct php.ini ? You can check it by running phpinfo and look where php load the ini file from.
by Suhoij
Thu Jun 16, 2011 2:20 am
Forum: PHP coding => General
Topic: PHP cURL Login Help
Replies: 10
Views: 2524

Re: PHP cURL Login Help

You would set the cookie file. You must have the "cookie.txt" file in similar with your script directory. And set 777 permissions to it. $post_data['username'] = $username; $post_data['password'] = $password; $post_str = ''; foreach($post_data as $key => $value) { $post_str .= $key. '=' .urlencode($...
by Suhoij
Wed Jun 15, 2011 12:26 pm
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

you're welcome )
by Suhoij
Wed Jun 15, 2011 12:25 pm
Forum: PHP coding => General
Topic: mysql plus array_unique
Replies: 5
Views: 1593

Re: mysql plus array_unique

$row contains associative array . You can check it by doing print_r($row);. So all you need is $row.
by Suhoij
Wed Jun 15, 2011 9:26 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

Sorry put the ob_end_flush() instead of echo ob_get_fkush().
by Suhoij
Wed Jun 15, 2011 8:41 am
Forum: PHP General
Topic: need helps for google API
Replies: 2
Views: 866

Re: need helps for google API

Did you receive new key for your site?
by Suhoij
Wed Jun 15, 2011 8:05 am
Forum: PHP coding => General
Topic: mysql plus array_unique
Replies: 5
Views: 1593

Re: mysql plus array_unique

This must work. <?php mysql_connect("localhost", "root", "Welcome@123") or die(mysql_error()); mysql_select_db("sharepoint") or die(mysql_error()); $query = "SELECT client FROM client"; $result = mysql_query($query) or die(mysql_error()); $arraydirty = (''); while($row= mysql_fetch_array($result)){ ...
by Suhoij
Wed Jun 15, 2011 7:53 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

Put <?php ob_start(); ?> in the header file in the first line. Then put <?php echo ob_get_flush(); ?> to the last line of the footer.
by Suhoij
Wed Jun 15, 2011 7:45 am
Forum: PHP coding => General
Topic: blog includes problem
Replies: 0
Views: 609

Re: blog includes problem

You can't do this without iframe. What I propose to do is to create the news from rss - parse rss from your blog and put them to this page.
by Suhoij
Wed Jun 15, 2011 7:32 am
Forum: PHP coding => General
Topic: mysql plus array_unique
Replies: 5
Views: 1593

Re: mysql plus array_unique

Sorry, what do you want to do? You have much of similar clients in database and wants to show the unqie only?
by Suhoij
Wed Jun 15, 2011 7:27 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

You don't need something specific - just start buffering on page start and echo buffer content on page end. But I would preffer first case - it is more natural way ( true way).
by Suhoij
Tue Jun 14, 2011 9:30 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

Or the second way is using buffer. Read about ob_start, ob_get_contents. This functions can help you.
by Suhoij
Tue Jun 14, 2011 9:28 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

Ok only one thing you must to do - is recode your script that setcookie appears in first line of your page. Take all php code and put it before DOCTYPE. Instead of echo the strings - save them and then echo wherever you want.
by Suhoij
Tue Jun 14, 2011 7:52 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

Please give the full code to understand whats happens. Thank you.
by Suhoij
Mon Jun 13, 2011 3:00 am
Forum: PHP coding => General
Topic: Headers issue
Replies: 22
Views: 4250

Re: Headers issue

What kind of the error did you get?
by Suhoij
Tue Nov 23, 2010 3:46 am
Forum: PHP coding => General
Topic: buttons always refresh page?
Replies: 0
Views: 508

Re: buttons always refresh page?

I think by default <button> tag the same as submit. So you need <input type="button">. To make it works you need put some action. <button type="button" onclick="alert(1)">Click</button>.
by Suhoij
Thu Aug 26, 2010 4:52 am
Forum: mySQL & php coding
Topic: "Table doesn't exist" error in php script
Replies: 1
Views: 868

Re: "Table doesn't exist" error in php script

I have no answer to this question - try to ask mysql developers about it )