Counting of lines

Discussion in 'PHP' started by frenchi1966, Dec 11, 2008.

  1. #1
    Hi,

    sorry, my question might be simple but i am new to this subject.

    How can i see a linenumber ie. 241 ín a php file.?

    Very often you have infos like change in line nr xxx the following text.

    I am displaying php files on my host and have no clue which entry i hve to do get the line numbers displayed.

    thanks in advance for your help,

    Regards
     
    frenchi1966, Dec 11, 2008 IP
  2. seregaw

    seregaw Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Hi,

    
    <?php
    echo __LINE__;
    echo __LINE__;
    echo __LINE__;
    
    ?>
    
    PHP:
     
    seregaw, Dec 11, 2008 IP
  3. seregaw

    seregaw Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    For past to html part of php file, use: <?=__LINE__?>
     
    seregaw, Dec 11, 2008 IP
  4. frenchi1966

    frenchi1966 Peon

    Messages:
    42
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #4
    When i am in the PHP file i write this command?
     
    frenchi1966, Dec 11, 2008 IP
  5. newgenservices

    newgenservices Well-Known Member

    Messages:
    862
    Likes Received:
    21
    Best Answers:
    0
    Trophy Points:
    105
    Digital Goods:
    1
    #5
    If you are using a IDE / Editor or such as Dreamweaver to go to a line, just use CTRL + G and enter line number and press enter
     
    newgenservices, Dec 11, 2008 IP
  6. junkmailbox53

    junkmailbox53 Peon

    Messages:
    69
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    After reading this ...I was hoping someone would suggest an application the would work with HTML and PHP as I find myself using notepad and wordpad.

    An application that is common and would word with text view and Page view ??/

    GPL Of course....
     
    junkmailbox53, Dec 11, 2008 IP
  7. joebert

    joebert Well-Known Member

    Messages:
    2,150
    Likes Received:
    88
    Best Answers:
    0
    Trophy Points:
    145
    #7
    Notepad2 has line numbers and is simple like Notepad, for Windows.
     
    joebert, Dec 12, 2008 IP
  8. Kaizoku

    Kaizoku Well-Known Member

    Messages:
    1,261
    Likes Received:
    20
    Best Answers:
    1
    Trophy Points:
    105
    #8
    Notepad has line numbers too, it's in the status bar.
    Ln 1, Col 1
    Code (markup):
     
    Kaizoku, Dec 13, 2008 IP
  9. chopsticks

    chopsticks Active Member

    Messages:
    565
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    60
    #9
    ConText works well and it's free, google it.
     
    chopsticks, Dec 13, 2008 IP