Jump to content

aspnetguy

Members
  • Posts

    6,787
  • Joined

  • Last visited

Everything posted by aspnetguy

  1. You don't need to learn that much javascript...if you feel comfotable with your level in JS then you can skip that one.If you already know some PHP you could just continue with PHP instead of ASP.Net...unless you really want to learn .Net.
  2. Have you ever done any programming before??? JavaScript????Based on what you know already you should learn this.1. JavaScript2. ASP.Net3. SQL (MySql)4. XML
  3. aspnetguy

    Can't insert

    nevermind I figured it out.Just not used to mysql syntax
  4. aspnetguy

    Can't insert

    Well, I am now learning php and I am having trouble inserting a recordhere is my code <?phpinclude('db.php');include('authenticate.php');if($action == "add"){ $topic_name = $_POST['topicname']; $topic_pass = $_POST['topicpass']; $topic_pdf = $_POST['topicpdf']; $topic_notes = $_POST['topicnotes']; if($topic_name == "") $msg = "Enter topic name"; elseif($topic_pass == "") $msg = "Enter password"; elseif($topic_pdf == "0") $msg = "Select PDF"; else { $db = mysql_connect($db_server,$db_usr,$db_passw); @mysql_select_db($db_name) or die( "Unable to select database"); $sql = "INSERT INTO Topics "; $sql .= "('TopicName','KeyCode','Pdf','Notes') "; $sql .= "VALUES('$topic_name','$topic_pass','$topic_pdf','$topic_notes')"; mysql_query($sql); mysql_close($db); $msg = "Topic added"; }}?><html><head> <title>Admin Area - Add Topic</title> <link type="text/css" rel="stylesheet" href="../scripts/admin.css"/></head><body><form action="?action=add" method="post"><table> <tr> <td>Topic Name:</td> <td><input type="text" name="topicname" id="topicname" style="width:150px" value="<?php echo $topic_name?>"/></td> <tr> <tr> <td>Topic Password:</td> <td><input type="password" name="topicpass" id="topicpass" style="width:150px" value="<?php echo $topic_pass?>"/></td> <tr> <tr> <td>Topic Pdf:</td> <td> <select name="topicpdf" id="topicpdf"> <option value="0">Select PDF</option> <option value="testpdf.pdf">testpdf.pdf</option><?php//read pdf folder?> </select> </td> <tr> <tr> <td>Notes:</td> <td><textarea name="topicnotes" id="topicnotes" rows="4" columns="25"><?php echo $topic_notes?></textarea></td> </tr> <tr> <td colspan="2"> <input type="submit" value="Add Topic"/> <input type="button" value="Cancel" onclick="java script:history.back()"/> </td> </tr></table><div style="display:block"><?php echo $msg?></div></form></body></html> Any ideas as to why it won't insert...it displays "topic added" but when I check the db it is not there.
  5. aspnetguy

    Include Annoyances

    Make sure your hosting account allows SSI, some don't...although I don't know why they shouldn't.
  6. Well give it a shot and if you just can't get it...post your full code (page with the iframe and the page inside the iframe) and I'll take a look at it.
  7. aspnetguy

    HOW TO...

    or if you get a camera phone you can take pictures and then email them to your friends from your phone.
  8. ok in that case it should work...I didn't think of that.Your code that manages this variable will have to be on the page that contains the iframe...then on each page that will load in the iframe execute a function that will change the value of the variable on the page with the iframe.Am I making sense?
  9. Your SELECT statement would go something like this SELECT * FROM tablenameWHERE YEAR(DateField) = YEAR(getDate()) That statement would get every record from the table that was from this yearyou could also do this SELECT * FROM tablenameWHERE YEAR(DateField) = 2004 to get all records from 2004...fill in the year you wish to retreive...you could have a drop down list on your application that allowed your boss to choose the year then have his selection inputed intot he SQL statement before executetion.This code is for SQL Server but I think it will work in Access too since they are both MS
  10. This is in C# but it shouldn't be too hard to convert to VB int z,x; x=0; char[] charList = new char[2]{'x','a'}; byte[] byteList = System.Text.UnicodeEncoding.Unicode.GetBytes(charList,0,charList.Length); for(z=0;z<byteList.Length;z++) { if(byteList[z] != 0) { Response.Write(charList[x] + "="+byteList[z] + "<br>"); x++; } }
  11. you'd be better off storeing all in one database regardless of the year and just add a date field to each record that way when you query you can filter by year.
  12. Javascript will not work between pages....if you change the value of lstpages on one page and then move to the next the value is reset when you load the script.Maybe I am not understanding your question.
  13. IE does not support this...it only works with a:hover unfortanutelyYou will need to do thisli a:hover
  14. No it wouldn't.He is telling you this becuase browsers can render those situations differently...it is a bit quirky.If you follow his advice that sorts everything out, use <br> like he said.... is not the same.<br> = line break = space
  15. <div style="width:100%;text-align:center"><INPUT style="WIDTH: 10%; ALIGN: left" TYPE="submit" NAME="PREV" VALUE="Prev"><INPUT style="WIDTH: 45%; ALIGN: center" TYPE="submit" NAME="REFR" VALUE="Refresh"><INPUT style="WIDTH: 10%; ALIGN: RIGHT" TYPE="submit" NAME="NEXT" VALUE="Next"></div> do that
  16. Yeah, through the week I pretty much live here 9-5...so I usually respond quickly .Good luck learning ASP...if you have any questions don't hesitate to ask.
  17. Me too, but I am sure that was just one of your 'I am the best' statements and the site in question doesn't even exist.Eric, if you would stop for just a moment and review what has happened...You initiated this whole mess by demanding Jonas lose his mod status...but you have been, over and over, far more rude, insulting, and just plain arrogant...what should we think???If I notice anymore of your immature crap then I will submit a formal request to have you ban permantly...I think there are plenty of people that feel the same way.Just grow up!
  18. INSERT is only used to add new records to the database...are you trying to add a new record or update an existing one???
  19. Eric, And why do you think that might be???Valuable resource huh? Well any amount of knowledge you bring to this forum is vastly out weighed by the controversy and trouble you bring to it.When you first came to this forum I had respect for the knowledge you obviously have...needless to say that is no longer the case.You seem to like definitions...you should look up the definition of the word class. I am not talking about programming, I am talking about having it.
  20. var ax=document.getElementById('table_id').rowsax[1].style.textAlign="center" or var ax=document.getElementById('table_id').rowsax[1].className="css class name" With the class name you have to define your css class first
  21. if you practice everyday and work hard, you should be comfortable with processing forms, selecting/updating/inserting,etc in databases in a few months.Practice is the key!
  22. there seems to be a lot of people experiencing this. Perhaps a mod should start a sticky post and have everyone that ahs this problem post there pc setup and browser version, etc.This needs to be resolved.
  23. aspnetguy

    SQL Problem

    good point, I never noticed that before.I always enclose in (") in my staements as well.
  24. Of course...I think this would be the best way...it also eliminates spam being posted.
  25. I am having trouble getting hte asp pages to run...I have ASP.Net installed...I don't know if that is interferring or not. I am frustrated
×
×
  • Create New...