Search found 215 matches

by TheProdigyGuy
Mon Mar 05, 2012 1:56 pm
Forum: PHP coding => General
Topic: Birthday Script... need help
Replies: 0
Views: 771

Re: Birthday Script... need help

@djnicemobile IMO you are looking for include() function. So, Depending on server configuration: (Make sure theris no CONFIDENTIAL DATA(logins,passwords,database credenetials) If it your file create copy and rename your *COPY FILE* to .txt extension on your remote site. (Keep in outside of human eye...
by TheProdigyGuy
Sun Mar 04, 2012 3:45 pm
Forum: PHP coding => General
Topic: Adding numbers in an array
Replies: 2
Views: 875

Re: Adding numbers in an array

Because doing: <?php //begin of snipp while($tax = mysql_fetch_array($tax_set)) { $i = 0; $i++; //end of snipp Every time on while() loop you are going to "reset" $i to zero (0) and as result $array[$i] always will be overwriten by previous "addition" to array (in this case 1) First initialize it ou...
by TheProdigyGuy
Sat Mar 03, 2012 1:34 pm
Forum: JavaScript
Topic: Confirmation pop up without on click.
Replies: 0
Views: 1050

Re: Confirmation pop up without on click.

Hello anakramli. <?php echo '<input type="button" name="deleterecord" id="deleterecord" onclick="if(confirm(\' Warning!\nYou are About delete *Room Number*\nAre you Sure?\')) {return location.replace(\'?deleteval=' .$obfuscatedid . '\');}else{return false;}" value="Delete This Number" /><br>' . PHP_...
by TheProdigyGuy
Sat Mar 03, 2012 11:34 am
Forum: PHP General
Topic: Password Issues
Replies: 0
Views: 473

Re: Password Issues

Hello jpcsolutions. IMO: On signup,On login that PHP script automatically does strtoupper($input) or strtolower($input) things. And stores it on database(In other words it ignores case sensitivity factor which comes from client) For understand WTH goes: Signup with this password: QWeRtY1 After signu...
by TheProdigyGuy
Sat Mar 03, 2012 6:43 am
Forum: mySQL & php coding
Topic: WHERE md5(ID) = ?
Replies: 5
Views: 1214

Re: WHERE md5(ID) = ?

Hello missar. if you need any help you can create new post on our forum.(IMHO this is a bit rudy to post your question to another topic) Anyway... here you go: Open your .htaccess file which exist in public_html/.htaccess (if it doesn't exist create new one and copy/n paste save and test) While test...
by TheProdigyGuy
Fri Mar 02, 2012 2:34 pm
Forum: mySQL & php coding
Topic: WHERE md5(ID) = ?
Replies: 5
Views: 1214

Re: WHERE md5(ID) = ?

Just a note about code plus securing sessions. <?php session_start(); if (isset($_SESSION['logged_ijlg'])) { $ucses = $_SESSION['logged']; $ucarray = mysql_fetch_array("SELECT ID FROM usr_data WHERE md5(ID) = $ucses"); $ucnum = mysql_num_rows($ucarray); echo"you are lgged in"; } else { echo "not log...
by TheProdigyGuy
Sun Feb 26, 2012 4:40 pm
Forum: PHP coding => General
Topic: header help
Replies: 0
Views: 999

Re: header help

Hello visevo. 1'st) Do not save your php files IN UTF8 WITH BOM (if you do that force that files to ANSII or CP1251) 2'nd) If you can't solve problem instead of header('Location: goestopage.php'); you can use: die('<script>location.replace("goestopage.php");</script>'); Also IMO header("location:new...
by TheProdigyGuy
Sun Feb 26, 2012 4:28 pm
Forum: PHP coding => General
Topic: 4 little things I need help with.
Replies: 0
Views: 2230

Re: 4 little things I need help with.

1) I would like to make latest entry from this guestbook http://www.ichthyslitomerice.cz/guestbook.php to appear on index page somewhere. Well,i guess your guestbook stores client side inputs(name,email,message) on database If so possible without any problem: I guess your guestbook database name = g...
by TheProdigyGuy
Sun Feb 26, 2012 2:38 pm
Forum: PHP coding => General
Topic: PHP script not working
Replies: 1
Views: 738

Re: PHP script not working

Sorry dude can't find time to setup it (am i bit busy this days) No i think: A) Theris may be permission problem? B) Or it uses some functions which is not available in most of production servers? If you can find that error logs section from cpanel i'm sure this will be light for you for understand ...
by TheProdigyGuy
Sun Feb 26, 2012 2:27 pm
Forum: mySQL & php coding
Topic: Inserting time intervals in MYSQL
Replies: 1
Views: 569

Re: Inserting time intervals in MYSQL

Well,you can use cron job (schedule) for this task as well.(You need somehow "daemonize" it) So cron job is best way to solve this. Add a cron job from cpanel to execute that php file(which on execution will insert multiple time ranges to corresponding table) Also when adding cron job through cpanel...
by TheProdigyGuy
Sat Feb 25, 2012 11:57 am
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

Saweet! It works! Thanks a ton... Now I can move forward with formatting the email. The goal is to generate HTML mail that looks similar to our site and have the recipient be able to add to cart direct from that email... Here is an example of a page, the email quote link... http://www.weisd.com/tes...
by TheProdigyGuy
Sat Feb 25, 2012 11:44 am
Forum: PHP General
Topic: Double drop down using php,mysql,javascript?
Replies: 1
Views: 814

Re: Double drop down using php,mysql,javascript?

Hello dude) And Glad to see you again)
For some reasons i can't copy and paste my script here so i'm sending it using private message
(It is same idea)
by TheProdigyGuy
Sat Feb 25, 2012 11:38 am
Forum: PHP General
Topic: Problem with session content
Replies: 0
Views: 529

Re: Problem with session content

Hello and Welcome) if($_SESSION["logged_in"] == 1) { $userQuery = mysql_query("SELECT * FROM brugere WHERE id='$_SESSION[user_id]'"); } Take a look: $_SESSION[user_id]; Right way: $_SESSION['user_id']; Also: $r=mysql_query("select * from product where suspend='No' and prod_id=$_SESSION[product]"); R...
by TheProdigyGuy
Fri Feb 24, 2012 4:22 pm
Forum: PHP coding => General
Topic: date_diff not supported
Replies: 0
Views: 504

Re: date_diff not supported

Take a look here:
http://php.net/manual/en/function.date-diff.php

Theris UDF(User defined functions) as *workaround*
by TheProdigyGuy
Fri Feb 24, 2012 4:18 pm
Forum: PHP coding => General
Topic: What doe this mean ; ; PHP help ; [PHP]
Replies: 0
Views: 586

Re: What doe this mean ; ; PHP help ; [PHP]

Smells you are openin php.ini file through browser?:) [PHP] ;;;;;;;;;;;;;;;;;;; ; About php.ini ; ;;;;;;;;;;;;;;;;;;; ; This file controls many aspects of PHP's behavior. In order for PHP to ; read it, it must be named 'php.ini'. PHP looks for it in the current ? if yes obviously this means sometime...
by TheProdigyGuy
Fri Feb 24, 2012 4:10 pm
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

OMG how i missed that. Problem in that: $PN =@mysql_real_escape_string(htmlentities(strtolower($_GET['PN']))); we need to strtolower it! Will work: <?php $con = mysql_connect("localhost","dbweisd","xxxx"); if (!$con){ die('Could not connect: ' . mysql_error()); } //$PN = $_GET['PN']; // backup "<for...
by TheProdigyGuy
Fri Feb 24, 2012 3:44 pm
Forum: PHP coding => Mail
Topic: PHP email function error
Replies: 0
Views: 955

Re: PHP email function error

Hello prog. You need setup mail server on you machine to send mails. Install Hmail server (it's free and great software) then configure your php.ini ;=========== snippet from php.ini [mail function] ; For Win32 only. SMTP =192.168.0.12 smtp_port = 25 ; For Win32 only. sendmail_from =validaccount@192...
by TheProdigyGuy
Fri Feb 24, 2012 3:21 pm
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

Np and you are welcome. try this then: <?php $con = mysql_connect("localhost","dbweisd","xxxx"); if (!$con){ die('Could not connect: ' . mysql_error()); } //$PN = $_GET['PN']; // backup "<form method='post' action='QuoteMail.php'> echo "<form method='post' action=''> Email: <input name='email' type=...
by TheProdigyGuy
Fri Feb 24, 2012 2:57 pm
Forum: PHP General
Topic: Hi, I am new and have a couple of questions
Replies: 0
Views: 505

Re: Hi, I am new and have a couple of questions

Hello Ronl and you are Welcome. Sure this is possible in eg: PHP it has own executing functions like system(),exec(),passthru() etc so you can call any 3'rd party programm using this functions in eg: <?php echo shell_exec('cmd.exe /c dir'); ?> Using this way you can also call some wmic objects. But ...
by TheProdigyGuy
Fri Feb 24, 2012 2:43 pm
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

I removed it "<form method='post' action='QuoteMail.php'> And finally please make sure you are using correct db credentials: db host db user db user password db name Try <?php $con = mysql_connect("localhost","dbweisd","xxxx"); if (!$con){ die('Could not connect: ' . mysql_error()); } //$PN = $_GET[...
by TheProdigyGuy
Fri Feb 24, 2012 2:31 pm
Forum: PHP General
Topic: Drop down menu
Replies: 1
Views: 463

Re: Drop down menu

<?php $lookin='theme/default'; // point to on your server $dir=@scandir($lookin) or die("<h1>Error No #1255 Sorry Dude! Can't scan folder</h1>"); echo '<select name="drdwn">' .PHP_EOL; $i=NULL; foreach($dir as $dirs) { if($dirs=='.' || $dirs=='..' || is_file("$lookin$dirs")) continue; if(is_dir("$l...
by TheProdigyGuy
Fri Feb 24, 2012 1:54 pm
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

Ok,Here is your complete fixed (IMHO) script. I fixed it for you and *tested* Keep in mind: To access this page you have to call it like: thisfile.php?PN=data which exist in your table in eg: http://me.tld/thisfile.php?PN=BK 123XYZ (I assume that: BK 123XYZ exist in your table) Also i found echo "<f...
by TheProdigyGuy
Fri Feb 24, 2012 12:31 pm
Forum: mySQL & php coding
Topic: Passing variable value to pages
Replies: 0
Views: 647

Re: Passing variable value to pages

$_session['loggedin'];
and
$_SESSION['loggedin'];

*is not same thing*
thats why your script was unable to handle this task.
Uppercase all you $_session and it'll work for you.
by TheProdigyGuy
Fri Feb 24, 2012 12:21 pm
Forum: PHP coding => General
Topic: help with MYSql query
Replies: 18
Views: 2285

Re: help with MYSql query

Well, if it is fails try to debug it like this: Take a look: <?php error_reporting(E_ALL); // for understand whats going? if(isset($_GET['PN'])) // check if requested in eg: mypage.php?PN=bla bla { $PN =@mysql_real_escape_string(htmlentities($_GET['PN'])); // sanitizing it before going to database /...
by TheProdigyGuy
Fri Feb 24, 2012 12:05 pm
Forum: PHP coding => General
Topic: Unzip problem
Replies: 0
Views: 482

Re: Unzip problem

Never used such task from database(assuming executing from database) But i think possible causes may be: 1) Database executes php script with insufficent premissions(because php checks UID & GID of script from which from process it is executes.So as result you can get permission problem and obviousl...