Jump to content

aspnetguy

Members
  • Posts

    6,787
  • Joined

  • Last visited

Everything posted by aspnetguy

  1. Isn't it a bug in the feature? IE says it supports setAttribute but htis attribute doesn't work.
  2. Your welcome. I am glad you found what you needed.
  3. You just want to open a new pagein the frame??? Or have the layout change but keep the same content?If it is the second choice then you need a server side lanaguage like ASP to do this.
  4. You could use a scripting language like ASP or PHP to automatically save the file to their computer instead of using a direct link to the file.
  5. Thanks Jonas...I appreciate your sympathy...lol
  6. aspnetguy

    IE sucks!

    I found a bug in IEI tried using setAttribute("style", cssStyles);and it does not work in IE. So I had to use the ugly work around like this var theDiv = document.createElement('div'); theDiv.setAttribute('id','cropArea'); imgParent.appendChild(theDiv); var cropAreaDiv = document.getElementById('cropArea'); cropAreaDiv.style.border = '1px dashed #000'; cropAreaDiv.style.background = '#dedede'; cropAreaDiv.style.filter = 'alpha(opacity=50)'; cropAreaDiv.style.position = 'absolute'; cropAreaDiv.style.top = y1.value + 'px'; cropAreaDiv.style.left = x1.value + 'px'; cropAreaDiv.style.width = dw + 'px'; cropAreaDiv.style.height = dh + 'px'; instead of just 2 lines like this var cssStyle = "..the styles...";theDiv.setAttribute("style", cssStyles); Man I hate IE. Is there a cleaner work around???Thanks.
  7. You just say that your solution doesn't use javascriptthen.... boom...javascript...how is that better then calling the javascript directly????
  8. This should have been moved to .Net not ASP
  9. I recommend buying one that is already out there. Paypal is the easiest form of payment (for the programmer) becasue the security is handled on the PayPal site. If you do not want this and want to accept credit cards, you need to handle the security.This is a very complex and serious issue. You can get into a lot of trouble if personal information is stolen due to poor security. You will definatley have to have some sort of encrytion like SSL.ASP.Net has good security methods too.
  10. Usually most forums let you edit the CSS directly. You can edit colors, formatting, images, etc from here.You will need to know CSS, HTML, and probably some image editing.
  11. As a matter of fact, there is!I have struggled with Session variables for a long time. They are always timing out whne they shouldn't!I came across Forms Authentication. It stores the user info in an encrypted cookie which will only expire when you say so!It took me a while to get it to work and it was a bit frustrating at first but now that it is up and running it is great.web.config <authentication mode="Forms"> <forms name=".ASPXUSERDEMO" loginUrl="/login.aspx" protection="All" timeout="60"> <credentials passwordFormat="Clear" > <user name="username" password="password"/> </credentials> </forms> </authentication> </system.web><location path="folder to protect"> <!--use / for all--> <system.web> <customErrors mode="Off"/> <authorization> <deny users="?" /> </authorization> </system.web></location> login.aspx <%@ Page Language="C#" Debug="true" %><%@ Import Namespace="System" %><%@ Import Namespace="System.Security" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"><html><head> <title>Page Title</title> <link rel="stylesheet" href="style.css" /> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /></head><body><script language="C#" runat="server"> //-------------------------------------- //Page Load //-------------------------------------- private void Page_Load() { if(IsPostBack) { } } //-------------------------------------- //Authenticate User //-------------------------------------- private void AuthenticateUser(string User, string Ticket) { if (FormsAuthentication.Authenticate(User, Ticket)) { FormsAuthenticationTicket ticket = new FormsAuthenticationTicket( 1, User, DateTime.Now, DateTime.Now.AddHours(3), false, "admin"); string encryptedTicket = FormsAuthentication.Encrypt(ticket); HttpCookie authenticationCookie = new HttpCookie(FormsAuthentication.FormsCookieName,encryptedTicket); Response.Cookies.Add(authenticationCookie); Response.Redirect(FormsAuthentication.GetRedirectUrl(User, false)); FormsAuthentication.RedirectFromLoginPage(User,false); } else { Response.Write("Error"); } } //-------------------------------------- //Login Button Click //-------------------------------------- private void LoginButton_Click(object sender, System.EventArgs e) {AuthenticateUser(Username.Value, Password.Value); }</script> <form runat="server"> <div style="padding:15px;height:1px"> <table cellpadding="0" cellspacing="0"> <tr> <td>Username:</td> <td><input type="text" id="Username" runat="server" class="InputField" /></td> </tr> <tr> <td>Password:</td> <td><input type="password" id="Password" runat="server" class="InputField" /></td> </tr> <tr> <td colspan="2"> <input type="button" value="Login" id="LoginButton" runat="server" class="InputButton" OnServerClick="LoginButton_Click" /> </td> </tr> </table> <div id="PostBack" runat="server" class="PostBack" /> </form> </div></body></html> That is a sample of my site and how I got it to work. This works for any files in the folder specified in the web.config. No more doing checks on every page manually!
  12. aspnetguy

    Iframes

    on the page witht he iframes put this in the <style></style> or external stylesheet iframe{margin:0px}
  13. If they do not have access to the internet they can't access the rss if it is on the interenet.If you are setting this up on a intranet on your LAN then they can access it as long as they are connect to the LAN. But htey will not be able to access the sites the rss link to if those sites are on the interent.RSS is just a collection of links...they don;t work any different then if you manually wrote out a list of links on a page...you need interent access to go to a website.That would work to do the refresh.
  14. global.asa is an ASP file you can't use JavaScript in it (client side anyways)You can write a very easy script (client side) to find compatibility and browser info.
  15. 1.63KB, if you are talking about external js files, is the size of the script file.If you don't have flash in your page it iwll load faster. JavaScript and Flash aren't the same thing and do different things all together. Are you talking about JavaScript and VBScript? or JavasCript and ActionScript?? You need ot be more psecific. VBScript can do the same thing as JavaScript, I have no idea which one loads faster, but VBScript, I am guessing, would be less cross browser friendly since it is a MS language.If you mean ActionScript, ActionScript is how you program Flash and is not comparable to JavaScript.
  16. you can easily set the classname by x.className = 'theClassName'; this is how you create the elements and have them display <html><head><title>x</title><script type="text/javascript">function insertrow() { var x=document.getElementById("maintable"); var newRow = x.insertRow(2); newRow.style.background="#C0C9D4"; var td1 = document.createElement("TD") td1.appendChild(document.createTextNode("column 1")) newRow.appendChild(td1);}</script></head><body><table id="maintable"><tr><td class="ns"><form><input type="button" onclick="insertrow()" value="+"/></form></td></tr></table></body></html> You are creating a row so you have to create the columns aswell (you cannot use row.innerHTML) then you can put the proper text in the columns you created.
  17. why are you placing content outside the <body></body>? this is where content is supposed to go!You could try html,body{background-color:#xxxxxx} instead of just body{backgorund-color:#xxxxxx}
  18. BTW the target attribute has been depreciated in XHTML...I doubt they will bring it back just because you ask...you have to do this through JavaScript now!
  19. IE is not CSS2 compliant and is not web standards complient (FF is). This most likely the cause of the bug...IE just doesn't know how to handle it.Hopefully IE7 will be better.There are some CSS hacks to get around this.
  20. aspnetguy

    IE woes

    you do not change your .html to .xhtml to write XHTML you just use the XHTML DOCTYPE.
  21. aspnetguy

    Newbie

    To link 2 docs together you use <a href="docName.html">Click here</a> No you cannot use HTML to write games. First HTML is a web technology and second it is only for formatting and positioning text.If you really want to get into games you will have ot learn a programming language like C++. Believe me it is a long road to creating a game like Call of Duty.
  22. I wasn;t sure what you want...do you want a third column when the query is displayed or do you actually want to add a 3rd column to the table?I would go with the third column on on display...why maintain a thrid column in hte table when it is just based on values the table already has.
  23. aspnetguy

    IE woes

    1.1 is supposed to be written as xhtml-xml not text/html (so say the purists). Another reason is that IE doesn't understand xhtml-xml and switchs to Quirks Mode and you lose all the benefit of 1.1. It is easier to keep it consistent across all browsers by using 1.0 (or so I am told, I haven't really researched it much)
  24. SELECT ActualHours, EstimatedHours, (ActualHours/EstimatedHours) AS PercentCompleteFROM TableName That should work
×
×
  • Create New...