Jump to content

systech44

Members
  • Posts

    13
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

systech44's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hello, Zen Cart version 1.3.9h. I wish to design a page something like http://www.funkypigeon.com/Pages/PhotoUpload.aspx?ProductId=5755. But I o not get any point to start with. Please suggest me how can I start this, especially the image section - zoom in, zoom out, other ways to customize it. Thanks a lot in advance. Regards.
  2. Can anybody please show me some free gateway to send SMS. How do I write code to send SMS in PHP ? Please help.
  3. The code displayed is working properly in the localhost. But the code is not working from the server. The server is the linux version. I upload the same script in the server. Now I am trying to see the mac of my PC. I do not found it. My question is, 'Is there a way to get client's MAC address who is accessing the website?'. Please help.
  4. Hello, Please let me know what is the wrong with the following lines of code. I am trying to find the MAC Address of the user who is logging. When I am running the code in localhost it is working. But the same code is not working when I upload it in the server. <?php function getMac(){ exec("ipconfig /all", $output); foreach($output as $line){ if (preg_match("/(.*)Physical Address(.*)/", $line)){ $mac = $line; $mac = str_replace("Physical Address. . . . . . . . . :","",$mac); } } return $mac; } $mac = getMac(); $mac = trim($mac); echo $mac; ?> Please help. Thanks a lot in advance. Regards & Thanks.
  5. I am trying the following code to send SMS. <?php $gatewayURL = 'http://localhost:9333/ozeki?'; $request = 'login=admin'; $request .= '&password=abc123'; $request .= '&action=sendMessage'; $request .= '&messageType=SMS:TEXT'; $request .= '&recepient='.urlencode('+9898989898'); $request .= '&messageData='.urlencode("Hello World"); $url = $gatewayURL . $request; //Open the URL to send the message file($url); ?> But I am getting the following error message. Warning: file(http://localhost:9333/ozeki?login=ad...ta=Hello+World) [function.file]: failed to open stream: Connection refused in /home/vpe/public_html/_demo2/sms/sms2.php on line 13 Please help to rectify my code. Thanks a lot in advance.
  6. I wish to download the folder full with images from the server and save it to some location of my PC by default. Please help by providing some coding. Thanks in advance.
  7. Thanks for the reply. But I will be obliged if you please elaborate this matter. Also please try to modify the code, if possible. Thanks you once again.
  8. I wish to restore the data of tables of my database into Excel(.xls) or any other format. Below is my code. <?php mysql_connect("localhost","root",""); mysql_select_db("test"); $dbname = "test"; $dbhost = "localhost"; $dbuser = "root"; $dbpass = ""; $backupFile = "restore"; $backupFile = $dbname . date("Y-m-d-H-i-s") . '.gz'; $command = "mysqldump --opt -h $dbhost -u $dbuser -p $dbpass $dbname | gzip > $backupFile"; system($command); ?> There is no error. But I cannot see the output. Please tell me what is wrong with my code. Please rectify. My environment is as below: Windows XP WampServer Thanks a lot in advance.
  9. Please let me know what is the solution. I like to show the images from database along with the relevant information side by side. Please help.
  10. Hello, I have a situation regarding the displaying the image from MySQL database. Here is my code of upload the images to MySQL. <?php if(isset($_POST['upload']) && $_FILES['userfile']['size'] > 0) { $fileName = $_FILES['userfile']['name']; $tmpName = $_FILES['userfile']['tmp_name']; $fileSize = $_FILES['userfile']['size']; $fileType = $_FILES['userfile']['type']; $fp = fopen($tmpName, 'r'); $content = fread($fp, filesize($tmpName)); $content = addslashes($content); fclose($fp); if(!get_magic_quotes_gpc()) { $fileName = addslashes($fileName); } $conn = mysql_connect("localhost", "root", ""); mysql_select_db("test", $conn); $query = "INSERT INTO pics VALUES ('','$fileName', '$fileType', '$fileSize', '$content')"; mysql_query($query, $conn) or die('Error, query failed'); echo "<br>File $fileName uploaded<br>"; } ?> <html> <head> <title>Pic Upload</title> </head> <form method="post" enctype="multipart/form-data"> <table width="350" border="0" cellpadding="1" cellspacing="1" class="box"> <tr> <td width="246"> <input type="hidden" name="MAX_FILE_SIZE" value="2000000"> <input name="userfile" type="file" id="userfile"> </td> <td width="80"><input name="upload" type="submit" class="box" id="upload" value=" Upload "></td> </tr> </table> </form> </html> Here is my code for the displaying the images from MySQL. //echo "Hello "; $errmsg = ""; if (! @mysql_connect("localhost","root","")) { $errmsg = "Cannot connect to database"; } @mysql_select_db("test"); $query = "SELECT content, type from pics where id = '1'"; $result = @MYSQL_QUERY($query); $data = @MYSQL_RESULT($result,0,"content"); $type = @MYSQL_RESULT($result,0,"type"); header("Content-type: $type"); echo $data; In this situation if I display the image without any string the it is displaying. But if I remove the comment from echo "Hello" then it is not working. I am trying to display the image in a <td></td> of table with info in other <td></td> with width amd height of <ing> tag specified. Please let me know what is the solution regarding the situation. Thanks a lot in advance.
  11. Sorry sir this code unable to store the values in Session variables. Is there anything better. Thank you in advance.
  12. I want to know how to retrieve values from Se;ect option and Check Box option and stored them in Session variables. I am trying with the folllowing snippet of code. But this is not working. please help. Thank you in advance. [code=php:0] <?php // Session1.php if(isset($_POST["spreads"], $_POST["major"], $_POST["minor"])) {       session_start();       $_SESSION["spreads"]=$_POST["spreads"];       $_SESSION["major"]=$_POST["major"];       $_SESSION["minor"]=$_POST["minor"]; } ?> [/code] [code=php:0] <?php // Session2.php session_start(); $spreads=""; $major=""; $minor=""; if(!empty($_SESSION["spreads"])) {       $spreads=$_SESSION["spreads"];       $major=$_SESSION["major"];       $minor=$_SESSION["minor"]; } echo "Spreads: ".$spreads."<br>"; echo "Major: ".$major."<br>"; echo "Minor: ".$minor."<br>"; session_destroy(); ?> [/code]
  13. Is it possible to handle HTML form element from php ? Also let me know if it is possible to write down the entire HTML coding via php. Following are my few queries on it. 1. How to assig two or more Group Box side by side. 2. How to accsess a picture from a folder withing my current project. Is it possible to allocate text and      picture side by side ? These are very urgent queries for me. Please try to help me.
×
×
  • 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.