Jump to content

mariocesar

Members
  • Posts

    84
  • Joined

  • Last visited

Everything posted by mariocesar

  1. This one is the one that changes, in the morning was 72.88.158.150 and now is 71.172.139.2 now is working fine but later is going to change. any other way?
  2. Ho can I authenticate base on hostname?
  3. thanks, i did it and works, but the IP changes all the time, is a dynamic one. this is a part of the script, please any other idea will be appreciate, thanks.
  4. I build a site that is use for sales reps. is all about prices and images of products we offer, they have to log in with their user name and password to get access to this site, the login PHP script keeps this site available from 9am to 6pm ,everything is working fine. now they asked me to match the IP address on each sales rep. computer in order for them to get access to the prices. that means they can only have access to the prices from the computer at work, any idea on how to do this. thanks Mario.
  5. Hi the day timing is working but the weekend part is not, still allow access to the users on weekends, any idea why? here is the code <?php $hour = date('H');//hour 1-24 $dayofweek = date('N');//numeric day of week 1=mon, 7=sun if($hour < 9 || $hour > 16 || $dayofweek > 5) { echo 'Could not be logged in. Site is closed'; }else { //login code } ?> Thanks.
  6. Hello, check this link http://autoshow.autos.msn.com/autoshow/Detroit2008/photogallerypopup.aspx?cp-documentid=6009726&photo-number=1# check the flash on top, at the end of the animation is a button "expand to interact" when you go over a panel open, how is this posible, please any tutorials or links where I can get some information, thanks.
  7. Thanks, this takes care the week days, from 9.00 am to 5.00 pm, how can I block the access on weekends, thank you.
  8. Hello, please help, I build a site, you can call it an internal info system for sales reps. (24 sales reps.) is working with a php. login system, each one with his own user and password, there is very private info on close to 20 php. pages about sales and prices, my question is how can I let them get access to the site from 9.00 am to 5.00pm and not access at all on weekends, thank you.
  9. The script is working but when you fill the text field keeps showing the message (how did you hear about us?) this validation is working fine the only thing I want to add is when the visitor choose "other" from the drop down menu, to make them fill the text box "type other here", here is the original code: <script language="javascript"> function validate(form) { if (form.Name.value.length == 0) { alert("Please enter your name.") form.Name.focus() return false } if (form.Address.value.length == 0) { alert("Please enter your Address.") form.Address.focus() return false } if (form.City.value.length == 0) { alert("Please select your City.") form.City.focus() return false } if (form.State.value.length == 0) { alert("Please select your State.") form.State.focus() return false } if (form.Zip.value.length == 0) { alert("Please select your Zip.") form.Zip.focus() return false } if (form.Phonenumber.value.length == 0) { alert("Please enter your phone number, with area code.") form.Phonenumber.focus() return false } if (form.email.value.length == 0) { alert("Please enter your e-mail address.") form.email.focus() return false } if (form.email.value.indexOf("@") == -1) { alert("Please enter a valid e-mail address."); form.email.focus(); return false; } if (form.AdSource.value.length == 0) { alert("Please enter how did you hear about Us?.") form.AdSource.focus() return false } } and here is the part of the form where the text " type other here" suppose to be fill, thanks. <FORM ENCTYPE="multipart/form-data" method="POST" action="contacton.php" name="form" > <tr><td colspan="2"><P><font color="#FF0000">*</font><FONT color=#3366cc>How did you hear about us?</FONT> <SELECT name="AdSource" id="AdSource"> <OPTION selected>Select</OPTION> <OPTION value=Google>Google</OPTION> <OPTION value=Yahoo>Yahoo</OPTION> <OPTION value=MSN>MSN</OPTION> <OPTION value=Intelecard Magazine>Intelecard Magazine</OPTION> <OPTION value=The Prepaid Press>The Prepaid Press</OPTION> <OPTION value=Direct Magazine>Direct Magazine</OPTION> <OPTION value=American Printer>American Printer</OPTION> <OPTION value=Print Professional>Print Professional</OPTION> <OPTION value=Printing Impressions>Printing Impressions</OPTION> <OPTION value=Other>Other</OPTION> </SELECT> <INPUT class=mednavtext maxLength=36 size=24 value="Type other here." name="OtherSource"></P></td></tr></form> Thank you.
  10. Hi, this form is working fine when the user don' fill the field the script promts them to do it works fine, how can I make the user fill "other" when they chosse other in the drop down menu, here is the script and the form } function validate(form) { if (form.AdSource.value.length == 0) { alert("Please enter how did you hear about Us?.") form.AdSource.focus() return false } } this is the form <tr><td colspan="2"><P><font color="#FF0000">*</font><FONT color=#3366cc>How did you hear about us?</FONT> <SELECT name="AdSource" id="AdSource"> <OPTION selected>Select</OPTION> <OPTION value=Google>Google</OPTION> <OPTION value=Yahoo>Yahoo</OPTION> <OPTION value=MSN>MSN</OPTION> <OPTION value=MSN>Intelecard Magazine</OPTION> <OPTION value=MSN>The Prepaid Press</OPTION> <OPTION value=MSN>Direct Magazine</OPTION> <OPTION value=Other>Other</OPTION> </SELECT> <INPUT class=mednavtext maxLength=36 size=24 value="Type other here." name="OtherSource"></P></td></tr> thanks in advance.
  11. thanks but I can not add the separate div for each thumbnail, because everything is dynamic here is the link one more time http://www.flexoplateonline.com/product/salesshetehtm2.php a php script populates the image and the rest of the description, quantities and prices if you go over the image, shows you a biger image that is fine, but when you go to a product in the midle of the page you can not see the image because it shows all the way on the top, please help. how can I see the image rgth on the screen even if I go to product #20. thanks
  12. thanks phpQuestioner, but don't work here is the link http://www.flexoplateonline.com/product/salesshetehtm2.php as you can see when you go to the product on the boton you can not see the image because displays all the way to the top. Thanks
  13. Hello, I have this script that pull info from a table pluss a link to an image allready in a folder, when you go over the image. it display the original image size, works fine the problem is that now I have more than 35 products and when the user roolls over the image the image displays ok but all the way to the top, so the user can not see the image, here is the script: <div align="center"><img src="<?php echo $row['productimage']; ?>" width="60" height="60" border="0" onMouseOver="javascript: showDetails('<?php echo $row['productimage']; ?>');" onMouseOut="javascript: offDetails();"> </div> <div align="left" style=" float:left; position:absolute; display:none; z-index:10; padding-left:11px; padding-top:10px; padding-right:11px; background-color:#DFE6E3;" id="det"> <img src="" id="img5" name="ing5" style="border:0px solid #666666; z-index:10;"></div> here is the js: <script language="javascript" type="text/javascript"> function showDetails(x) { document.getElementById('det').style.display=''; document.getElementById('img5').src=x; } function offDetails() { document.getElementById('det').style.display='none'; } </script> How can I see the image rigth on the screen, thanks
  14. Hello, I have this script that pull info from a table pluss a link to an image allready in a folder, when you go over the image. it display the original image size, works fine the problem is that now I have more than 35 products and when the user roolls over the image the image displays ok but all the way to the top, so the user can not see the image, here is the script: <div align="center"><img src="<?php echo $row['productimage']; ?>" width="60" height="60" border="0" onMouseOver="javascript: showDetails('<?php echo $row['productimage']; ?>');" onMouseOut="javascript: offDetails();"> </div> <div align="left" style=" float:left; position:absolute; display:none; z-index:10; padding-left:11px; padding-top:10px; padding-right:11px; background-color:#DFE6E3;" id="det"> <img src="" id="img5" name="ing5" style="border:0px solid #666666; z-index:10;"></div> here is the js: <script language="javascript" type="text/javascript"> function showDetails(x) { document.getElementById('det').style.display=''; document.getElementById('img5').src=x; } function offDetails() { document.getElementById('det').style.display='none'; } </script> How can I see the image rigth on the screen, thanks
  15. thanks, but gives me an error: Parse error: parse error, unexpected T_WHILE in /home/content/m/a/r/mariovicuna/html/dumpinfo.php on line 17 while ($i < 11) is line 17: $i = 0 while ($i < 11) {
  16. hi, I got this table is working fine but just the first row is upload in to my sql table, how can I feed the complete info all 11 rows at once, here is the code (table): <form method="POST" action="dumpinfo.php" name="form" > <table width="750" cellspacing="1" cellpadding="3" > <tr> <td><div align="center">productid</div></td> <td><div align="center">baseprice</div></td> <td><div align="center">quantity</div></td> <td><div align="center">5peroff</div></td> <td><div align="center">10peroff</div></td> <td><div align="center">15peroff</div></td> <td><div align="center">20peroff</div></td> <td><div align="center">25peroff</div></td> <td><div align="center">30peroff</div></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr> <td><font color="#003366" > <input name="productid" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="baseprice" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="quantity" type="text" size="12"> </font></td> <td><font color="#003366" > <input name="fiveperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="tenperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="fifperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="twfperoff" type="text" size="8"> </font></td> <td><font color="#003366" > <input name="thrperoff" type="text" size="8"> </font></td> </tr> <tr><td colspan="9" align="center"><input type="submit" name="Submit2" value="Submit" onClick="return validate(form)"> <INPUT type="reset" value="Cancel"> </td></tr> </table></form> //and here is the php script: <?php /////////////////////// CONNECT TO MYSQL DB //////////////////// // OPEN CONNECTION ---> $connection=mysql_connect('securebut', $user = "productdetail", $pass = "loco07") or die("Unable to connect!"); /* change this! */ mysql_select_db("productdetail") or die("Unable to select database!"); /* change this! */ // EXECUTE QUERY ---> $query="INSERT INTO productdetail ( productid, baseprice, quantity, 5peroff, 10peroff, 15peroff, 20peroff, 25peroff, 30peroff) VALUES( '".$productid."', '".$baseprice."', '".$quantity."', '".$fiveperoff."', '".$tenperoff."', '".$fifperoff."', '".$twperoff."', '".$twfperoff."', '".$thrperoff."')"; //////-----> $result=mysql_query($query) or die("Error in query:".mysql_error()); if ($result) echo mysql_affected_rows()." Thanks, Mario a record was inserted into the database effectively, go back and insert the next one, You are the Best"; // CLOSE CONNECTION ---> mysql_close($connection); ?></td></table> Thanks in advance.
  17. Thanks, Questioner may be folder permissions?
  18. Please help, this script works fine in my machine I use Dreamwaver to build pages and when I test the page work perfectly fine, but when I upload it to the hosting server don't work, here is the scrip. <script language="javascript" type="text/javascript"> function showDetails(x) { document.getElementById('det').style.display=''; document.getElementById('img5').src="php_uploads/uploads/"+x; } function offDetails() { document.getElementById('det').style.display='none'; } </script> and this is the part where the image shows it self on mouse over: <table cellspacing="3" cellpadding="2" align="center" class="sample"> <tr> <td rowspan="4" height="80" width="180"><div align="center"><img src="php_uploads/uploads/161107040021.jpg" width="55" height="80" border="0" onMouseOver="javascript: showDetails('161107040021.jpg');" onMouseOut="javascript: offDetails();"></div></td> <td width="94">CR-80 <div align="left" style="position:absolute; display:none; padding-left:11px; padding-top:10px; padding-right:22px; background-color:#DFE6E3;" id="det"> <img src="" id="img5" name="ing5" style="border:0px solid #666666;"></div> </td> </tr></table> thanks.
  19. Hello, this is a .swf quote form file that when you open in your computer woks fine, but when I enbed the file in a html page don't work, I use a decompiler software to get the .fla file make some changes and posted in my site but as I told you before don't work, I know this .swf work with .PHP files wich I don't get access to, there are located in the original server, my question is why the .swf works when I opened on my PC and doesn't when I embed the .swf to an .html, if this is a wrong forum sorry for that is any way to get the php files to work with this .fla file. if you know a very good flash forum will be great, here is the link to the .swf embeded http://www.flexoplateonline.com/quote1.html Thanks Mario Vicuna
  20. Hello, this is a .swf quote form file that when you open in your computer woks fine, but when I enbed the file in a html page don't work, I use a decompiler software to get the .fla file and make some changes this file is working fine after the changes maybe don't work as an embeded file because it points to a different server. Is there a solution in this case here is the link of the html with the .swf enbed, http://www.flexoplateonline.com/quote1.html Thanks Mario Vicuna
  21. Hello, how can I change the color of text on a mail content, if I want to make the color of Company, Name, Address, City (green) here is the code $mailContent="--------Contact--------\n\n" ."Company: ".$company."\n" ."Name: ".$firstname."".$lastname."\n" ."Address: ".$address."\n" ."City: ".$city."\n" ."State: ".$state."\n"; Thanks.
  22. Thanks, now they can see the coupon number $result = mysql_query("SELECT * FROM `digicoupons` WHERE `Email`= '$Email'" ) or die(mysql_error()); $row = mysql_fetch_array( $result ); echo " coupon number: ".$row['userID']; Thanks, solved.
  23. the name of the field is couponID, I want this record to show next to the message "Thank you! Now You can print the coupon and send it with your order." the script is working I just want to pull the couponID field and echo it to the user here is the table: CREATE TABLE `digicoupons` ( `timeStamp` timestamp(14) NOT NULL, `couponID` mediumint( NOT NULL auto_increment, `Name` varchar(50) binary NOT NULL default '', `Company` varchar(50) binary default NULL, `Email` varchar(100) binary NOT NULL default '', PRIMARY KEY (`userID`), UNIQUE KEY `couponID` (`couponID`,`name`) ) TYPE=MyISAM AUTO_INCREMENT=1002 ; thanks.
  24. This is a small form and the script grabs the info and insert it into a dbase, in the dbase is an auto icrement field that I want to show together with the message that goes back to the user when they submit the form, here is the script: <? $Name=$_POST['Name']; $Company=$_POST['Company']; $Email=$_POST['Email']; if($Email){ } else{ $error.=""; } if($error==""){ echo "Thank you! Now You can print the coupon and send it with your order."; $connection=mysql_connect('localhost', $user = "mario", $pass = "mario") or die("Unable to connect!"); /* change this! */ mysql_select_db("freesamples") or die("Unable to select database!"); $query="INSERT INTO digicoupons ( Name, Company, Email) VALUES( '".$Name."', '".$Company."', '".$Email."')"; //////-----> $result=mysql_query($query) or die("Error in query:".mysql_error()); mysql_close($connection); } else{ print "Sorry, but the form cannot be sent until the fields indicated are filled out completely - <br>\n"; print "$error<br>\n"; print "<br>\n"; print "<br>\n"; print "Please use your \"Back\" button to return to the form to correct the omissions. Thank you.<br>\n"; } ?> Thanks.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.