Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
O

offroaderdan

@offroaderdan
About
Posts
131
Topics
49
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Stop a page moving upwards
    O offroaderdan

    Hi guys, I have a small question, I am creating a website and have created a table using ul elements. (I used ul as this was easier to animate using javascript and it does what i want.... I did try using tables and it messed up. When I click on one of the ul items the page stays where it is. However when i click another one the page then shoots to the top. I have read around and some people say do the following

    blah

    However this still sends the page to the top. If any body knows any tips/tricks as to how to solve this it would be mighty helpful.

    JavaScript javascript tutorial question

  • Adding a link to a table built in Javascript
    O offroaderdan

    Hi all, This is hopefully a very simple question however I do not know the answer to it. I am trying to link a cell from a table created in Javascript to another function.

    var cell_1 = document.createElement("td");
    cell_1.style.textAlign = "center";
    cell_1.appendChild(document.createTextNode("Hi"));
    onclick = myFunction();

    This code ALL works apart from the onclick function, all I wanted to do is when the cell is clicked for example an alert message pops up. Hopefully that makes sense and if anybody can help that would be helpful :)

    JavaScript javascript help tutorial question

  • Video not playing in a .php file
    O offroaderdan

    Experts, I use to have a .html file which worked fine :) I then decided to add some php code which then meant i had to change the extension of the file. Now i have some flash videos which use to automatically play but now they don't... I am using dreamweaver and even tried using insert, media, flash video and still no luck :( I kinda need these videos to play and the reason for the flash is all part of the security of the website :) If any body can help that would be great Dan (I didn't really know which section to put this in so sorry if i did put it in the wrong section)

    Linux, Apache, MySQL, PHP php html adobe security help

  • Link through javascript
    O offroaderdan

    Hi thanks for your reply! I will be disallowing browsers such as internet explorer which is < version 6 as my website will not function correctly in it. I tried the location.replace('oops.html') but nothing happened. The code i need something simular to this if interent explorer <6 then open url opps.html else do nothing In the javascript i cannot get the url to load the page. Thanks

    JavaScript help question javascript html tools

  • Link through javascript
    O offroaderdan

    Experts, I have a problem which i need help with, I have a javascript page which will detect the users browser, if it is below a certain defined state another webpage will be displayed saying. Unfortunatly your web browser is not up to date. This has all been done however how do i link pages through javascript? i thought this would work however it doesn't

    document.write("<href='oops.html'>");

    I have also tried closing the javascript and opening a html tag (would look something like this)

    </script>

    <a href="../MWHAHA website/oops.html"></a>
    <script type="text/javascript">

    all i would like to do is open a html page if a statement is true or not. If anybody can help that would be great Cheers Dan

    JavaScript help question javascript html tools

  • MYSQL connect through PHP
    O offroaderdan

    Hi, I have an email through my web hosting service which has told me my database details. they go MySQL Hostname: 99.99.999.999 MySQL Username: xxx xxx MySQL Passwor: aaaaahh MySQL Server: MySQL 1 I was able to connect to a differnet database which did not have mysql server on it by using the following code $hostname = "99.99.999.999"; $password = "aaaaahh"; $username = "xxx xxx"; Now i thought that this was simply going to be adding a $server variable on underneath so the complete code would look like this $hostname = "99.99.999.999"; $password = "aaaaahh"; $username = "xxx xxx"; $server = "MySQL 1"; $connection = mysql_pconnect($hostname, $server, $username, $password); if (!$connection) { die('Could not connect: ' . mysql_error()); } echo 'Connected successfully'; mysql_close($connection) ?> However this doesn't seem to do anything? Any help would be great Many Thanks Dan

    Linux, Apache, MySQL, PHP php database mysql sysadmin hosting

  • A HTML page not display a PHP page on button click ERROR 404?
    O offroaderdan

    Experts, I have uploaded a simple site with a HTML page and a PHP page. Supposedly on a click on the HTML page the the php file should then run but it says that the page cannot be found. I don't get this because it is in the same place as the HTML file and all the directories seem to be fine. i've even tried to go onto the web address and have the php file linked after e.g www.google.co.uk/example.php but then it comes up saying page not found Any ideas? Dan

    Web Development php html help tutorial question

  • Body on load, doesn't seem to work?
    O offroaderdan

    Experts, I have a website i am currently (trying) to make :) I have a piece of code which goes

    <body onLoad="disptime()","MM_CheckFlashVersion('7,0,0,0','Content on this page requires a newer version of Adobe Flash Player. Do you want to download it now?);DisplayDIV('SubKicks');HideDIV('LeftDiv');HideDIV('RightDiv');HideDIV('FrontDiv');HideDIV('SideDiv');">

    Which doesn't seem to do what it is suppossed to do. disptime is a javaScrpt function which displayes the current time. the MM checks flash is because i have some videos i have added. Now the main thing that isn't working is this part DisplayDIV('SubKicks');HideDIV('LeftDiv');HideDIV('RightDiv');HideDIV('FrontDiv');HideDIV('SideDiv'); In my HTML code i have Display and Hide javascript functions, which will allow me to hide and show certain DIV tags. I am confused at why the body tag doesn't like the display and hiding divs as this EXACT code works fine onClick on a button..... (I need it onLoad) If anybody can help that would be great. I assume i have missed out a semi colon or something somewhere but don't actually know where!??!?!? Many thanks Dan

    Web Development adobe javascript html help question

  • Div tags visble and hidden
    O offroaderdan

    OK i seem to be getting somewhere.......However, is there any way that i can change the background image of another button by pressing a particualr button. What i have is a button which when rolled over goes red, and clicked goes green ( ad should stay green!!) What i then want to do is only when a mouse click is on another button the orignal green button goes back to orginal and the clicked button becomes green. I have a rough idea of how to do it except but don't know if it would actually work :) Current code

    <input type="image" onClick= "hideSK();hideRK();showFK();this.src='images/Main screen/Main buttons/Welcome.jpg';MM_callJS('roll')"

                    onmouseover="this.src='images/Main screen/Main buttons/WelomeRed.jpg'" 
                    onMouseOut="this.src='images/Main screen/Main buttons/Welcome.jpg'"
                    value="Welcome" src="images/Main screen/Main buttons/Welcome.jpg" width="146" height="43"
    

    I would then like to add a function which will change the previous buttons back to blue something like button.value="home".image scr= "home blue.jpg Thanks Dan

    Web Development csharp question

  • Div tags visble and hidden
    O offroaderdan

    Thanks, This works, however i have some button images i would like to use, i have tried as best to use your code and incorprate it into the image i am using but hit a brick wall. i used

    <img src="images/MainScreen/Welcom.jpg" name="Welcome" width="146" height="43" onClick="mouseout()">

    but his code doesn't seem to be doing anything, unlike your code above. Any help would be great Cheers Dan

    Web Development csharp question

  • Div tags visble and hidden
    O offroaderdan

    Experts, I have a div tag i have assigned with 3 pictures in it. lets call it

    now what i would like to happen is on mouse hover on a separate button this div tag is displayed (visible), and on mouse out it becomes invisible. Any ideas of how this can be done. I am sorry if this is a stupidly easy question to answer, i am use to coding in vb.net and thought i would have a go at a different language :) as in vb.net i wold do groupbox.visible=false. Thanks Dan

    Web Development csharp question

  • Setup wizard.....Not visible
    O offroaderdan

    Experts, Why can i not create a setup wizard? I have VB.net 2005 (express edition) but i don't seem to have a setup wizard pack. When i click file, add new project, i am given like only 4 choices. On google it says go on to "other" and then select setup wizard........ I havent got an other tab?? Can any body help?? Cheers Dan

    Visual Basic csharp help question workspace

  • Splitting a text box with commas in it
    O offroaderdan

    Experts, I have a textbox which will generate a set of random numbers, e.g 10 , 4 , 6 , 3 , 2 , 1 .... What i need to do is to basically split this textbox up into lots of textboxes. I was originally using e.g

    txt1.text = mid(txt0.text, 1,txt0.textlength - 7)

    this was ok if you where using numbers below 10 but now i am not, so i have split my numbers using commas but how do i sort them into the differnet text boxes using the commas as splitting points? Many thanks Dan

    Visual Basic question lounge

  • web browser in vb.net.
    O offroaderdan

    Experts, I have a web browser in vb.net, works like a treat :) However is there any way that on a button click in the html web page through vb.net, can i then have a button that is invisible in vb.net to be then be visible to the user on the vb page. e.g the web page is shown but the user doesn't do any thing. - nothing happens the user types something in - nothing happens on the vb side the user types something in a presses the submit buttons - a vb button appears allowing them to continue. Any ideas? Dan

    Visual Basic csharp html question

  • Splitting a .txt file and sorting it
    O offroaderdan

    hmmmm there seems to be something not right with the code. I dont have to define SortedList of anything like that, as it still doesn't like

    Ian Shlasko wrote:

    SortedList(Of Integer, HighScore)

    I really am grateful for all the help Dan

    Visual Basic algorithms help

  • Splitting a .txt file and sorting it
    O offroaderdan

    WOW thanks, However i am having a few probelms, the

    Ian Shlasko wrote:

    SortedList(Of HighScore)

    doesn't seem to work, I have put this code under a button click and it comes up with an error saying "no accessible 'sorted list' accepts this number of type arguments"? I am really grateful of the time you put in explaining in depth what is needed, it was just strange that it ain't working. I am using vb.net 2005, in normal design mode (not in console) if thats any help :)

    Visual Basic algorithms help

  • Splitting a .txt file and sorting it
    O offroaderdan

    WOOOOOO it actually seems to work. Quick question though I tried to trick the code to see if the sort is actually working and it doesn't appear to sort the highscores into numerical order. All i actually done was just move the highest score to the bottom of the text file, so only one of them was out of sync. There also seems to be an error on button click, which i think is part of the sorting.

    Private Sub comtest_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles comtest.Click
    username = Text1.Text
    userscore = Val(Text2.Text)
    For i = 1 To 10
    a = scores(i)
    If userscore >= a Then
    test1(i) = username
    test2(i) = userscore
    For b = i + 1 To 10
    test1(b) = names(b - 1) ' comes up with an error saying ArgumentOutOfRage index was out of range, must be non-negative
    test2(b) = scores(b - 1)
    Next
    Call newscore()
    Exit Sub
    End If
    test1(i) = names(i)
    test2(i) = scores(i)
    Next
    End Sub

    Any ideas Many thanks for all the help Cheers Dan

    modified on Wednesday, April 14, 2010 10:46 AM

    Visual Basic algorithms help

  • Splitting a .txt file and sorting it
    O offroaderdan

    Thanks a million Tosch. It is really annoying when you spot stupid mistakes like that. I am still getting an error on under the sub heading highscores on listBox1.Items.Add(names(i)) The error is ArgumentOutOfRangeException was unhandled? AND the index was out of range. must be non-negative and less than the size of the collection. Parameter name:index Any ideas Cheers Dan

    modified on Wednesday, April 14, 2010 9:57 AM

    Visual Basic algorithms help

  • Splitting a .txt file and sorting it
    O offroaderdan

    Experts, Initally what i want to do is to sort 2 lots of data. 1 sort would be the highscore (the highest of the score, ad the second dort would be through the time (lowest). I dont't really know what the best way to do this, so that was why i thought i would ask you lot. I also will post up the code i am having a bit of trouble with. This may be able to cope with what i am wanting to do. I am using 1 button called comtest 2 list boxes called listBox1 and ListBox2 2 textboxes called text1 and text2

    Imports System.IO

    Public Class Form1
    Dim scores = New System.Collections.Generic.List(Of String)
    Dim names = New System.Collections.Generic.List(Of String)
    Dim test1(0 To 10) As String
    Dim test2(0 To 10) As Integer
    Dim userscore As Integer
    Dim username As String
    Dim a As Integer
    Dim b As Integer
    Dim i As Integer
    Dim strFilename As String = ("High Scores.txt")

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        Call highscore()
        names = New System.Collections.Generic.List(Of String)
        scores = New System.Collections.Generic.List(Of Integer)
        Dim srScores As New IO.StreamReader(strFilename)
        While Not srScores.EndOfStream
            Dim strRead As String = srScores.ReadLine
            ListBox1.Items.Add(strRead)
            Dim strSplit() As String = Split(strRead, ",")
            names.Add(strSplit(0))
            scores.Add(strSplit(1))
        End While
        srScores.Close()
    
    
    End Sub
    

    Private Sub comtest_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles comtest.Click
    username = Text1.Text
    userscore = Val(Text2.Text)
    For i = 1 To 10
    a = scores(i)
    If userscore >= a Then
    test1(i) = username
    test2(i) = userscore
    For b = i + 1 To 10
    test1(b) = names(b - 1)
    test2(b) = scores(b - 1)
    Next
    Call newscore()
    Exit Sub
    End If
    test1(i) = names(i)
    test2(i) = scores(i)
    Next
    End Sub
    Private Sub highscore()
    For i = 1 To 10
    ListBox1.Items.Add(names(i)) 'this always comes up with an error saying argument out of range
    List2.Items.Add(scores(i))
    Next
    End Sub
    Private Sub newscore() ' write
    ListBox1.ClearSelected()
    List2.ClearSelected()
    For i = 1 To 10
    ListBox1.Items.Add(test1(i))

    Visual Basic algorithms help

  • Database search function in php
    O offroaderdan

    Experts, I have a table in php which displays all serial numbers in the program. What i would like to do is when the user for example wants to find serial number ABCDEF123 they will type it in the text box and then press submit. I would then like all the other serial numbers to dissapear/hide and then just show tht serial number. I have created the text box and button in php but dont know how to do the above. If anybody could help that would be great Many thanks Dan

    Linux, Apache, MySQL, PHP tutorial php database help
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups