I have the following text
/department-sales-palermo-page-3.html
And I need to get everything that is after the 3 script (-)
The first thing I thought was doing
url = /departamento-venta-palermo-pagina-3.html
url[-13:]
and he returned me correctly
pagina-3.html
Now how can I solve the problem that instead of a digit the number is two digits example /department-venta-palermo-pagina-13.html since using the above I would be returning
agina-13.html
that would be wrong.