Jump to content

jesh

Members
  • Posts

    2,293
  • Joined

  • Last visited

Everything posted by jesh

  1. I've tried various jobs - bicycle mechanic, barista, warehouse manager, customer support, sales - but I always end up coming back to coding. So, I finally got myself a job doing it. It's definitely a career path for me - one that I enjoy.
  2. Two things appear to be happening here: The value of "msg" will always be "$mymsg" rather than the value that is assigned to your $mymsg variable. You would most likely run into problems with the spaces, ampresand (&) and angle brakets in the value. It needs to be url encoded. I'm not a PHP developer, so forgive me any errors, but something like this should fix it: $mymsg = 'Unon User Name & Password Plz Try Again <br>';header("Location: http://index.php?msg=".urlencode($mymsg)); Of course, you'll also need to decode the string once you get to the second page: $mymsg = urldecode($_GET['$msg']);
  3. That's the server side code, what's the rendered html look like? Also, like Henrik_76 asked, if you click on Tools -> JavaScript Console in Firefox's menu, what kind of error messages are you getting?
  4. jesh

    FTP to FTP

    Have you looked at the documentation?Connect to the FTP server (ftp_connect, ftp_login), get all of the file information as an array (ftp_nlist), loop through the array and get (ftp_get) the files. Then, once you have the files, loop through your file array and put (ftp_put) them on your server.I've never done this, but the documentation makes it seem like you should be able to.
  5. This tutorial (http://www.mredkj.com/tutorials/tutorial005.html) uses a try/catch block to attempt to add the option one way for standards compliant browsers and another for IE. It might help.
  6. Could you post to the php page using a form? <form id="SearchForm" method="POST" action="search_profile.php"> <input type="hidden" id="qry" name="qry" /></form> If you use javascript to populate the hidden input and to then submit the form, the "qry" parameter would be POSTed to the PHP page and the visitor wouldn't see it in the address bar as a query string.
  7. Can you use <?php ?> in your code to separate the PHP from the javascript? Something like this: <html> <head> <script type="text/javascript">function myfunction(){ // normal javascript functionality to go here...} </script> </head> <body><?php // PHP functionality to go here...?> </body></html>
  8. jesh

    duplicate into dbase

    I would suggest setting up your data so that you have three tables in your database: UserProfiles, Courses, User_Courses (or some other more intuitive name). UserProfiles: - UserProfileID - Username - Password - FirstName - LastName - etc...Courses: - CourseID - Title - Description - Credits - etc...User_Courses: - UserProfileID - CourseID This way you will have one UserProfile record for each user, one Course record for each course, and as many records as you want for the pairing of users and courses. If a particular user (say UserProfileID = 4) signs up for 4 courses (CourseIDs 5, 16, 22, and 31), your User_Courses table would contain: UserProfileID CourseID4 54 164 224 31 I hope this helps.
  9. If there was a record that you wanted to retrieve from your database which had a username of "robokopf", you'd want to use a SQL query something like the following:SELECT * FROM userdb WHERE username = 'robokopf' I think if you change your code to reflect that query you would be closer to your goal. strsql = "SELECT * FROM userdb WHERE username = '"&username&"'"
  10. jesh

    ASP.NET newbie

    Which is the error I got. I thought maybe it was since I had a Web.config file set up to display those errors. However, I deleted the web.config file and the I still got the "response does not exist in the current context".Looking closer at the error message, RightPilot: Have you looked at that log?
  11. jesh

    ASP.NET newbie

    Could it be your code? Your code as posted caused an error for me.Try changing it from: <html><body><%response.write("Hello World!")%></body></html> To: <html><body><%Response.Write("Hello World!");%></body></html> I don't have "Application Pools" in my IIS either, but I've been developing .NET stuff on this computer for years.
  12. You're correct that you wouldn't have to use anchors (<a href=""></a>) to allow a visitor to move to another page. The "location.href = " code changes the URL of the current page. In the example that I provided, if a visitor selected "Volvo" from your dropdown menu (AND s/he had javascript enabled), it would take him/her to a page on your site called "volvo.html". If you wanted the visitor to be sent to Volvo's webpage, you'd want to use "http://www.volvocars.com" as the value instead.Hope this helps!
  13. Thanks for the tip. If I ever lose this job, I can keep building .NET stuff. Do you use the Express version(s) yourself?
  14. You'll have to use a little javascript to do that. Something like this: <select id="cars" onchange="location.href = this.value"> <option value="volvo.html">Volvo</option> <option value="saab.html">Saab</option></select> Put the URLs to the car-specific pages as the values of your options and when the user changes the selection on the select menu, the onchange event happens and you'll set the location of the page to the URL for the selected car.
  15. This site (http://www.connectionstrings.com/) has saved me more times than I care to remember...
  16. Yeah, the only reliable way I ever found to connect to MySQL through .NET was to use the MyODBC drivers . It also looks like they've come out with ADO.NET drivers too, but I've never used them.I was never able to connect directly without using MySQL's drivers.
  17. As per the subject of your question, are you trying to link to certain areas within a single page using the #? If so, I don't see anywhere in your code where you actually specify that #. I would recommend either changing the values of the options from "001", "002", etc. to "#001", "#002", etc or changing your java script: <script type="text/javascript"><!--function go(){location= "#" + document.mywebcomics.id.options[document.mywebcomics.id.selectedindex].value}//--></script>
  18. Building a search engine can be quite a bit of work and I agree that you'll need PHP (or C#/VB and .NET) as well as a database. SQL Server and MySQL both allow FREETEXT searching on the database which can make finding results much easier.Here are a couple resources that might help (or cause great confusion )How a Search Engine WorksPopulating a Search Engine with a C# Spider
  19. Either you could set up an anonymous (or not anonymous) FTP server that people can log into so that they can upload files to your computer.Otherwise, if you use PHP or .NET, you could build a form which allows users to upload files.http://us3.php.net/features.file-upload (PHP Manual)http://www.tizag.com/phpT/fileupload.php (PHP Tutorial)http://www.codeproject.com/aspnet/fileupload.asp (ASP.NET Tutorial)
  20. jesh

    MySQL Error!

    I think, if it were me, I would contact the technical staff. Perhaps it's an error on their side.
  21. I wouldn't recommend using ASP. I think it's a dying technology since ASP.NET has come out. As a ASP.NET developer, I would recommend learning .NET (and C#), but only under the stipulation that you already own a copy of Visual Studio (which is wildly expensive). So, barring that, I would definitely recommend PHP.
  22. jesh

    INSERT Query

    Perhaps it has something to do with that "& #40;" that is in your query. Shouldn't that be a "("?
  23. jesh

    Link Hover States

    I don't know anything about a[target=_blank] - I've never seen that before - but you could use a javascript function to dynamically add classnames to your links on page load. This way you could use the traditional a.ExternalClassName:hover and a.InternalClassName:hover. Here's an example:function HighlightAnchors(){ var anchors = document.getElementsByTagName("a"); var count = anchors.length; var anchor; for(var i = 0; i < count; i++) { anchor = anchors[i]; if(anchor.target == "_blank") { anchor.className = "External"; } else { anchor.className = "Internal"; } }}
  24. You might try using the onclick event of the link to call a function which has two window.open calls in it:function OpenThem(firstUrl, secondUrl){ window.open(firstUrl); window.open(secondUrl);} <a href="#" onclick="OpenThem('http://www.mysite.com/page1.html','http://www.mysite.com/page2.html');">Do it</a>
  25. Check out this link which explains GROUP BY and HAVING:http://www.w3schools.com/sql/sql_groupby.asp
×
×
  • Create New...