Jump to content
UBot Underground

Scrape a little part of a div


Recommended Posts

I need to scrape a little part of a div and set it as a variable, but after trying it for 2 days now I can't figure out what to do, so I hope there is somebody that want to help me out here.

 

Below is the div and the only part I need is the country (in bold) that is different every time.

Is there a way to filter that part from the div and put it in a variable?

 

<div class="right">
            <div class="top_bar">
                <ul class="user_left">
                    <li class="user1"><span class="white">Money:</span> $<b style="font-weight:normal;" id="upd_money">0</b></li>
                    <li class="user_bar">|</li>
                    <li class="user2"><span>Bullets:</span> <b style="font-weight:normal;" id="upd_bullets">0</b></li>
                    <li class="user_bar">|</li>
                    <li class="user2"><span>Points:</span> <b style="font-weight:normal;" id="upd_points">0</b></li>
                    <li class="user_bar">|</li>
                    <li class="user2"><span>Health:</span> <b style="font-weight:normal;" id="upd_health">100%</b></li>
                    <li class="user_bar">|</li>
                    <li class="user2"><span>Country:</span> <b style="font-weight:normal;">South-Africa</b></li>
                    <li class="user_bar">|</li>
                    <li class="user2"><span style="color:#ff9393;">Crackers:</span> <b style="font-weight:normal;color:#93ffa0;">0</b>
                </li></ul>
            </div>

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...