PHP - Arcuturs Website Problem
I am using wampserver to run my website but i keep getting error when i type in localhost in my address bar
Is it the problem with wampserver or the coding? The Error Quote Warning: mssql_connect() [function.mssql-connect]: Unable to connect to server: localhost in C:\wamp\www\libs\dmssql.php on line 35 Cant Connect to mssql [dmssql class] here is the config.php Quote ##### Template Dir ########### $template = 'default'; ##### Server Name $title = 'RoseCP AE'; ###### Your msSQL Info ######## $hostname = "localhost"; $username = "sa"; $password = ""; # databases, that if you changed db names. if not, dont change a thing $seven_ORA = "seven_ORA"; $sho = "SHO"; $sho_log = "SHO_LOG"; $sho_mall = "SHO_MALL"; And here is the dmssql.php Quote ##### Template Dir ########### $template = 'default'; ##### Server Name $title = 'RoseCP AE'; ###### Your msSQL Info ######## $hostname = "localhost"; $username = "sa"; $password = ""; # databases, that if you changed db names. if not, dont change a thing $seven_ORA = "seven_ORA"; $sho = "SHO"; $sho_log = "SHO_LOG"; $sho_mall = "SHO_MALL"; And here is the dmssql.php Quote class dmssql { function dmssql($h,$u,$p,$d) { $this->host = $h; $this->user = $u; $this->pass = $p; $this->db = $d; } function connect() { $this->linkid = mssql_connect($this->host,$this->user,$this->pass) or die("Cant Connect to mssql [dmssql class]"); if ($this->linkid) { if (mssql_select_db($this->db)) { return TRUE; } else { $this->dbclose($this->linkid); echo "Cant Select $this->db [dmssql class]"; return FALSE; } } else { echo "Cant Connect to mssql [dmssql class]"; return FALSE; } } function query($q) { if ($this->connect()) { $q = $this->clean($q); $r = mssql_query($q) or die("FATAL ERROR"); return $r; } } function clean($string) { $new_data = preg_replace("[^A-Za-z0-9@.]", "", $string); return $new_data; } function num_rows($data) { return mssql_num_rows($data); } function qFirstRow($q) { if ($this->connect()) { $ret = mssql_fetch_row($this->query($q)); } return $ret[0]; } function fetch_array($data) { return mssql_fetch_array($data); } function dbclose() { return mssql_close($this->linkid); } } ?> Can you help me Please Guys :X i enbaled php_mssql.dll and i replaced from ;extension php_mssql.dll to extension php_mssql.dll Could you help me guys please X.x HERE IS The full website code im using http://uploading.com/files/get/8de48e5m/ Similar TutorialsHi, I have uploaded a website for someone but they are having problems viewing it and are telling me that nothing comes up. Not sure if its a dns problem. The domain was registered 2 days ago. Can a couple of you please check and tell me if this site loads up, it should show an ecommerce website : http://www.cassellmotors.com Many thanks, Scott Hi, I have create a small website with a login, over the past month it has been working fine, however today I tried to login and it says incorrect password. So I go into my phpMyAdmin database and change the password with the function type as PASSWORD. I go to login again and it still doesnt work. I did however have a dummy account on the site and that does work, and the only difference I can see is the encryption of the password, the new passwords I create start with the astrix symbol (*) and the old password that works doesnt have that. I can guess im probably using the wrong encryption type, but Iv tried loads of different ones and still nothing. I have however noticed which line of code in my PHP code isnt working for the new Passwords, but I cant see a problem. I have put it below, if anyone knows what the problem is, please, please, please let me know. Code: [Select] if ($pwd === PwdHash($pass,substr($pwd,0,9))) { It fails at this point and goes strait to the else at the bottom of the if statement. Thanks Ben p.s. if you want me to post all the Login code I will happily do so. So I'm working on a website for an airline (not real) and on one of my pages you can request the cost of a flight by putting in the depart and arrival locations, like this: And if they put in a selection that isn't in the database they get this: The problem is that when they load the page initially, instead of just the selection bars and sumbit button showing up, it all does and i get an error like this: When you sumbit it, it all looks like it should, it's just that when they load it things seem to go wrong, any idea how i can fix this? Heres the code i use: Code: [Select] <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post"> <p>Depart: <select name="depart"> <option selected="selected">Bristol</option> <option>Newcastle</option> <option>Manchester</option> <option>Dublin</option> <option>Glasgow</option> </select> Arrive: <select name="arrive"> <option>Bristol</option> <option selected="selected">Newcastle</option> <option>Manchester</option> <option>Dublin</option> <option>Glasgow</option> </select> <input type="submit" /> </p> </form> <?php $depart = $_POST['depart']; $arrive = $_POST['arrive']; $con = mysql_connect("localhost","root",""); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("test", $con); $result = mysql_query("SELECT price FROM flights WHERE depart = '$depart' AND arrive = '$arrive'"); if ($row = mysql_fetch_assoc($result)) { echo 'This flight shall cost you £'; echo $row["price"]; } else include('includes/price.php'); ?> </div> My if-else statement doesn't seem to be doing it's job Thanks in advance I am helping a friend to fix their website and I dont have too much experience with php. I have noticed a problem with the language on one of the pages http://www.fincalavicaria.com/alameda.php When the page loads the Servicios shows in Spanish, which is correct however, if you click on the Servicios link it changes to the English version in the Spanish vesrion. This should only be available after you have changed the language for the site to english at the top As I dont have too much experience I would be grateful if someone could tell me what would be causing this to happen. It should be something very easy to fix but no matter what I try I can't find the problem. Thank you. Code: [Select] <?php $ACCEPT_FILE['home'] = 'home.html'; $ACCEPT_FILE['general'] = 'general.html'; $ACCEPT_FILE['attorneys'] = 'attorneys.html'; $ACCEPT_FILE['contact'] = 'contact.html'; $ACCEPT_FILE['login'] = 'login.html'; $pagename = $ACCEPT_FILE[$id]; if (!isset($pagename)) $pagename = "home.html"; // default file include( $pagename ); ?> the url looks like: www.yoursite.com/index.php?id=general Ever since i think like php 5 came out i am unnable to load pages it just defaults to the home.html no matter what variable is defined. any ideas or help would be appreciated. Its almost like its not defining the pagename variable until the bottom where $pagename = "home.html". ive been looking at it and reading the manuals for hours and figured its time to make a post. thanks. I'm trying to make a League of Legends (a video game) community website, both as a personal project and for practice. Now the game has a lot of champions, each of whom have 5 unique abilities. Now, I thought about manually inputting all the details about each champion into a MySQL database, but that would long and tedious, and I don't really have the time for it now. Also, the game patches very oftern (like, once every 2 weeks) which changes many of the stats, etc. of the champion, and it is not possible for me to keep manually updating these every time there is a patch. Fortunately, there is a League of Legends Wiki which has all the data I need in their specific champion pages, which they keep updated per patch. So I was wondering if there was any way to get the data from the divs in the wiki, and have it display on my site. What I want to do in my website is that whenever someone types a champion's name (in a post or whatever), I want it to display a hover-over dialog with some of the champions details. And a lot of other features such as that. In plain English I need a way to : > Tell PHP to go to the wiki's source code on a specific page > Find a specific div container > Get X data from there > Pass X data into a function to display the hover-over I think this way, I would not have to maintain a database as I can leech off the wiki's data. I have not coded anything like this before, so I would like a few pointers as to how to achieve this. Any help will be appreciated! I tried searching on google but couldn't find any relevant information, please redirect me to relevant source or help me with the code. I want to pass a domain name in text field which will be scanned and then the script will display entire site map. Not external links or links on a page. Sorry it is not easy for me to explain. Eg. if i pass abc.com Script will display abc.com/12/adn.php abc.com/asd/asd/ etc Whatever their url format is. All the links on that domain. hello My database is in a same server with seperate domain name , then I want to insert from website1 mysql data on website2 mysql data. can anyone help me? Is it possible to download files from a website to my online websites root directory? reason I'm asking is because I have been downloading large video files to my computer which take about 20 minutes!! Then I use FTP to upload them to my site but it takes about 2-3 hours per video!! I was looking for a faster way! All help would be great! Hi, I haven't used any php for a while, but i am making a website, and i need some advice on how to do the following: I want the website to change an image once every 24 hours, the image will revert back to the original image after 2 minutes. Does anyone have an idea how I could start doing this? Hi there Can anyone please help me. I am trying to get my website working but i am struggling big time with the php. The things i need to do are not to complicated however my lack of skill with php is making me struggle. I need help in making the php work on my website. Can anyone help please. (Please note it is not a commercial or business website.) Anyone who can help please contact me. Thanks My code on website is not validate on W3 Validator.
<?xml version="1.0" encoding="ISO-8859-1"?> This would be an example of a page I'm referring to: http://www.curse.com...other-downloads
I want to get the file name and compare it to another name (to see if they are the same or not). I have no idea how to access that page from my website. I'm guessing PHP would be best although if you don't think so tell me what you think would be better (I was thinking javascript but don't think that's cross-site compatible). Is there a PHP function to get the value of the href which is in this case (as of this posting) "Railcraft 9.4.0.0".
I used inspect element to see the code of the page but have no idea if this is possible or if I'm even going about this the right way. The code would have to work on this entire website (all pages have the smae layout as this one though! Any help is greatly appreciated!
I am working on a website and I am at a standstill. I would rather speak to someone one on one but its been very difficult to find someone that could help. I have the scripts that I want but when I add the scripts to the mainpage everything stops working. I really don't want to go to wordpress because I am almost done with this one. Thanks.
Hello everyone and thank you for reading this.
My goal: Build a site like sportingnewschicago.com
What it does? It has different sectiions of different teams. Then it displays the tittle of the news and makes them be able to click on to go to the news site. The site some how checks a list of sites and post them on their respected section. But only ones that have not already been listed.
What i want to do? Well i want to try to learn how to do this. Is this something i can make with the help of members here? It would only have index.php and thats it.
Please let me know if anyone would be interested in teaching me as i do it. If not i would understand. Thank you.
Hello everybody!
I have been asked by a customer to develop a GTP website (Get To Pay, those websites where people earn money from clicking on ads). I managed to write the backend, signup and login but I am unsure how the ads part, with built-in user-tracking works and fallback link works.
I would really appreciate any kind of help.
Thank you very much!
P.S. For the user tracking I was thinking of sessions with matching ip and user agents together with an anti-proxy online service (e.g. MaxMind, Proxystop, ...)
I just signed up on Disqus.
Link: https://disqus.com/
My Question:
Can this commenting system only be used for those platfroms which one can choose?
I was looking to use this for my own web application (in PHP).
If this may not work with Disqus, is there something similar to Disqus out there, quick and easy to set up?
Hi, I have a requirement of making the single website for different locations, customer running a enterprise, and he wants me to show corresponding items for corresponding locations(nearly around 30 locations) I am very confused how to make this(making separate sub domains for separate location), pls help me regarding this. Thanks, Hi, I'm working on a design for a new website of mine, but I'm kind of stuck on how to fit in the php aspect of it. There's going to be a lot of different pages and different things you're able to do on each page. I guess I'm trying to figure out how to take my design for the website and break it up into a template system. I don't know anything about using templates though. The last time I tried to make a template I just winged it and it turned out really bad with a lot of confusing code slapped together with html all around it. Right now all I have is a single page made (front page) and I want to use this as my base template. Could anyone explain to me the proper way to go about this, or perhaps link me to a tutorial covering this. Thanks, hi, how can i make a autoupdate currency table currency value CHF USD EURO KD (Kuwaiti Dinars) 1 Converted Value Converted Value Converted Value when the page loads, it will convert the currency and the value of CHF, USD and EURO are real time please kindly help tia |