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
  1. Home
  2. General Programming
  3. Regular Expressions
  4. Help with pattern

Help with pattern

Scheduled Pinned Locked Moved Regular Expressions
regexjavascripthtmlhelpquestion
2 Posts 2 Posters 8 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    Phrone
    wrote on last edited by
    #1

    I need help with regular expression for a javascript I'm working on. I have some html code into a variable that is named xmlDoc. The string includes a table and there are some things there that I want to pick out with regex.

    6
    Prentice, Bob
    340584305858
    Logged out

    [Edit](javascript:doEditAgent("56746")),
    [Delete](javascript:doRemoveAgent("56746", "fn1")),
    [Log in](javascript:doLoginLogout("4", "56746","fn1"))

    In this code I want to pick out: 1. The name, "Prentice, Bob" 2. The status, "Logged out" 3. The content from doLoginLogout(), "4", "56746","fn1" What pattern(s) should I use? There are five rows similar to this in the table that I need to do this on.

    T 1 Reply Last reply
    0
    • P Phrone

      I need help with regular expression for a javascript I'm working on. I have some html code into a variable that is named xmlDoc. The string includes a table and there are some things there that I want to pick out with regex.

      6
      Prentice, Bob
      340584305858
      Logged out

      [Edit](javascript:doEditAgent("56746")),
      [Delete](javascript:doRemoveAgent("56746", "fn1")),
      [Log in](javascript:doLoginLogout("4", "56746","fn1"))

      In this code I want to pick out: 1. The name, "Prentice, Bob" 2. The status, "Logged out" 3. The content from doLoginLogout(), "4", "56746","fn1" What pattern(s) should I use? There are five rows similar to this in the table that I need to do this on.

      T Offline
      T Offline
      thatraja
      wrote on last edited by
      #2

      Probably you need to take a look at this[^] But to pick the name, status values, you may try document.getElementById, Look at this Get Value of a cell of HTML Table[^]

      thatraja


      My Dad had a Heart Attack on this day so don't...
      Pompeyboy3 here
      | Nobody remains a virgin, Life screws everyone :sigh:

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

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