PYTHON-beautifulsoup:
after selecting: divtotals = soup.find(id="od-subtotals")
I get this mess with multiple same class. I want select the last span which has $6.48
<div id="od-subtotals" class="a-fixed-right-grid-col a-col-right" style="width:260px;margin-right:-260px;float:left;">
<div class="a-row">
<div class="a-column a-span7 a-text-left">
<span class="a-color-base">
Item(s) Subtotal:
</span>
</div>
<div class="a-column a-span5 a-text-right a-span-last">
<span class="a-color-base">
$5.99
</span>
</div>
</div>
<div class="a-row a-spacing-mini">
</div>
<div class="a-row">
<div class="a-column a-span7 a-text-left">
<span class="a-color-base">
Total before tax:
</span>
</div>
<div class="a-column a-span5 a-text-right a-span-last">
<span class="a-color-base">
$5.99
</span>
</div>
</div>
<div class="a-row a-spacing-mini">
</div>
<div class="a-row">
<div class="a-column a-span7 a-text-left">
<span class="a-color-base a-text-bold">
Grand Total:
</span>
</div>
<div class="a-column a-span5 a-text-right a-span-last">
<span class="a-color-base a-text-bold">
$6.48 <!-- return this value -->
</span>
</div>
</div>
</div>
sorry I am new to this, I am writing this cause stackoverflow won't let me post showing error It looks like your post is mostly code; please add some more details. I hope this is enough details