Parsování HTML tagů z textu

Uživatelský avatar
RoliD
Administrátor
Příspěvky: 250
Registrován: pát 10. črc 2015 12:47:18

Parsování HTML tagů z textu

Příspěvek od RoliD »

Pokud je potřeba z textu vytáhnout nějaké tagy, tak to uděláme takto:

Kód: Vybrat vše

$html = "Nějaký text <img src=odkaz> s obrázkem a odkazem <a href=odkaz>odkaz</a>";

$doc = new DOMDocument();
@$doc->loadHTML($html);

$tags = $doc->getElementsByTagName('img'); 
$links = $doc->getElementsByTagName('a');

foreach ($tags as $tag) {
       echo "<a href=\"".$tag->getAttribute('href')."\"><img src=".$tag->getAttribute('src')." ></a>";
}

Návštěvník

Re: Parsování HTML tagů z textu

Příspěvek od Návštěvník »

Air Jordan 6
Nike Outlet
Nike Jordan 1
Golden Goose Shoes
Air Jordans
Yeezy Sneakers
Red Bottom Shoes For Women
Nike Snkrs Website
Golden Goose
Red Bottoms Louboutin
Pandora
Jordan 3
NMD R1
Yeezy
Air Jordan 12
Jordan Retro 11 Mens
Ferragamo Outlet
Jordan Shoes
Jordan 11 GYM Red
Air Max 270
Christian Louboutin
Jordans 2021
Jordan Retro 12
Jordans Retro
Vans Store
Nike Factory Outlet
Pandora
Air Force 1
Air Max 90
Yeezys
Hermes Birkin Bag
Moncler Vest
Adidas Yeezy Boost 350
Jordan 6 Rings
Golden Goose Sneakers
Nike Outlet Store
Jordan 12
Cheap Nike Shoes
Air Jordan 11
Lebron Shoes
Nike Outlet Store Online Shopping
Nike Factory Outlet
Jordan Sneakers
Air Max 95
Jordan 1
Jordan Sneakers
Air Jordan 10
Pandora Bracelet Charms
Nike Sale
Jordan 4 Retro
Air Jordan 12
Air Jordan 3 Retro
Kyrie Irving Shoes
Louboutin Shoes
Soccer Cleats
Jordan Retro
Retro Jordans
Men's Nike Shoes
Jordan 1
Fjallraven Kanken
Jordan 11's
Pandora Charms Outlet
Jordan 5
Air Jordan Sneakers
Air Jordan Shoes
Nike Outlet
Moncler
Jordans 11
Yeezys
Golden Goose Sneakers Outlet
Golden Gooses Sneakers
Moncler Jackets For Women
Jordans 1s
Moncler Store
Pandora Charms
Air Max
Air Jordan 4
Jordan 11 For Sale
Nike Air Jordan 1s
Sneakers GGDB
Cheap Jordan Shoes
Air Jordan 1 Low
Air Jordan 1
NMD
Adidas Yeezy
Air Jordans
Nike Outlet Store Online
GGDB Shoes
Air Jordan 14
Moncler Jackets Outlet
Asics Running Shoes
Pandora Charms
Valentino Sneakers
Jordan 6 Retro
Golden Goose Mid Stars
Golden Goose Sneakers Women
Pandora Ring
Retro Jordan 11
Jordan 13 Retro
Jordans
Jordan 13s
Air Jordan 11s
Nike Shoes
Jordan Retro 11
Jordan Retro 4
Red Bottom Shoes
Yeezy
Jordan Shoes
Jordan 12 Retro
Jordans 5
Moncler Coats
Jordan 9
Air Jordan 6
Golden Goose Sneakers Sale
Air Jordan 11
Nike Official Website
Louboutin Shoes
Women Nike
Air Jordan Sneakers
Jordan 11 Low
Pandora Official Site
Christian Louboutin
Nike Outlet
Jordan 4
James Harden Shoes
Shoes GGDB
Nike Air Max 98
Air Jordan 8
Christian Louboutin Shoes
Balenciaga Triple S
Jordan 1 Retro
Pandora Jewelry
Balenciaga Sneakers
ECCO
Nike Jordan
New Jordan 11
Pandora Charms
Golden Goose Factory Outlet
Air Max 2018
Huaraches Nike
Pandora Rings
Jordan 1
New Jordans
Pandora Charms
Air Jordan Sneakers
Air Max
Fitflop Sandals
Air Jordan Retro
Jordan 4
Nike Air Max 270
Cheap Jordan Shoes
Air Jordan 5
Christian Louboutin shoes
New Nike Shoes 2021

Návštěvník

Re: Parsování HTML tagů z textu

Příspěvek od Návštěvník »

Pandora Jewelry Official Site
Pandora Jewelry
Jordan 15
Jordan 25
Wholesale Nikes
Jordans 12
Nike Wholesale Dealer
Pandora Rings Official Site
Nike Jordan 1
Jordan 26
Nike Zoom Fly
Lebron Shoes
Red Bottom
Adidas Yeezy
Jordan 33
Nike Shox
Cheap Jordans
Toddler Jordans
Nike Zoom
NBA Store Canada
Ice Jersey
Jordan 32
Cheap Nike Shoes From China Free Shipping
Cheap Jordans
Nike Huarache
Nike Huarache
Air Jordan 29
Nike Shoes For Women
Nike Shoes
Jordans 2021
Jordans 13
Nike Air Max
Nike Air Force 1
Nike React
Jordan 31
Nike
Nike Outlet
Nike Off White
Air Max 720
Rings Pandora
Nike Roshe
Huaraches Nike
Wholesale Air Jordans
Nike Running Shoes
Air Jordan
Nike Running Shoes Women
Nike Air Max 270 Flyknit
Jordan 17
Jordan 12
Nike
Pandora Charms
Nike Factory
Nike Metcons
Air Jordan 20
Nike Sneakers
Adidas Wholesale
Jordan 11 Concord
Air Max
Jordans 16
Air Max 97
Pandora Charms Outlet
Air Jordan 13
Nike Air Max 270
Pandora Jewelry
Pandora Bracelet
Nike Outlet
Pandora
Nike Outlet
Jordan 19
Jordans 34
Cheap Jordan Shoes
Nike Jordan
Nike SB Dunk
Jordan 2
Adidas Store
Jordan 1
Jordan 33
Nike
NMD
Adidas Wholesale Distributor
Cheap Adidas Shoes
MLB Jerseys
Wholesale Jordans
Jordan 33
Nike Sneakers
Nike Roshe Men
Nike Outlet Store Online Shopping
Jordan 35
Pandora Jewelry
Wholesale Jordans From China Factory
Nike Outlet Store
Nike Outlet Store Online Shopping
Jordan 6s
Nike Air Max 95 Essential
Nike Outlet Store Online Shopping
Adidas Yeezy Boost 350 V2
NFL Shop Online
Wholesale Nike Shoes
Pandora Jewelry
Cheap MLB Jerseys
Jordan Retros
Air Jordan Shoes
Pandora Jewelry
Air Jordan 11 Retro
Adidas Shoes
Pandora Jewelry 70 Off Clearance
Air Jordan 14
Pandora CZ Charms
Nike Foamposite
Nike Hyperdunk
Christian Louboutin
Nike Free Run
Nike Air Max
Jordan 30
Jordan 11
Jordan 27
Nike Shoes
Nike Air Max 97
Louboutin Shoes
Nike Shoes
Kids Jordans
MLB Jerseys
Nike Air Force 1 Mid
Pandora Jewelry Official Site
Nikes
Air Jordan 22
Air Jordan Shoes
Air Max 720
Jordans 24
Jordan Retro 11 Low
Nike Air Force 1
Pandora Bracelet Charms
Jordan 4
Air Force 1s
Nike Wholesale
Nike Shoes Cyber Monday Sales
Nike Women's Shoes
Jordan 18
Pandora Bracelet
Air Force Ones
Nike Clearance
Jordan 28
Pandora Bracelet
Official Nike Outlet Online Store
Jordan AJ 1
Air Max
Pandora Outlet
NHL Jerseys
Nike Shoes For Mens
What The Jordan 5s
Wholesale Clothing
Jordan 21
Dior Jordans
Nike Shoes Wholesale
Nike Store
New Nikes Shoes
Jordan 12 Retro
Jordans 23
Pandora Jewelry
Pandora Jewelry Outlet


Návštěvník

Re: Parsování HTML tagů z textu

Příspěvek od Návštěvník »

Kanken Backpack
Nike Clearance
Nike Outlet
Louboutin
New Nike Shoes
Kyrie Shoes
Red Bottom Shoes
Nike Air Zoom Pegasus 36
Jordan 11 Retro
Nike Shoes For Men
Jordan 1 Mid
Nike Factory Store
Adidas Sneakers
Jordan 1 UNC
Nike Clearance
Pandora Charms
Nike Huarache Men
Red Bottom Shoes
Air Max 720
Nike Presto
Nike Air Force One
Air Max 98 Gundam
Nike Free Run
Pandora Jewelry
Air Max 98
Pandora Necklace Women
Nike Sneakers For Men
Womens Nike Shoes
Nike Zoom
Nike Outlet Store
Nike Shoes Cyber Monday
Kevin Durant Shoes
Yeezys
Pandora Canada
Mens Nike Shoes
Nike Outlet Online
New Air Max 2019
Pandora Jewelry Official Site
Lebron Shoes
Fjallraven Kanken Backpack
Red Bottom Shoes For Women
Jordan 4 Retro
New Jordans
Pandora Jewelry
Jordan 1 Retro High
Michael Jordan Shoes
Jordan AJ 1
Louboutin Shoes
Lebron Shoes
Pandora Charms
Pandora Earrings
Jordan 11 Gamma Blue
Pandora Jewelry
Pandora
Pandora
Pandora
Nike Air Jordan
Jordan Shoes For Men
Jordan Sneakers
Ultra Boost
Jordan Retro
Air Jordan 11
Nike Sneakers For Women
Jordan Shoes For Kids
Jordans Sneakers
Yeezys Boost 350 V2
Pandora Bracelets
Ferragamo Belts
Christian Louboutin Shoes Outlet
Air Jordan 11
Nike Cortez
Air Force Ones
Nike Shoes
Nike Shoes
Nike Air Max 95 Essential
Nike Air Max
Nike Outlet Store
Jordan 32
Nike Shoes
Air Force 1 Mid
Asics Shoes
Vans Outlet
Christian Louboutin Sale
Jordan 1s
Jordan Retro 13
Nike Outlet Store Online Shopping
Nike Factory Outlet
Yeezy Shoes
Nike Outlet Store Online Shopping
Christian Louboutin shoes
Cheap Basketball Shoes
Air Jordan 10
Nike Outlet Store Online Shopping
Sneakers Website
Air Jordans
Yeezy Boost
Nike Shoes
Ferragamo Outlet
Nike Air Monarch
Air Force 1
Jordan 12
Nike Air Max 270 Men
Air Jordan Shoes
Air Max 720
Air Jordan 13 Retro
Kyries Shoes
Yeezy 700
Louboutin Outlet
Jordan Shoes
Nike Shoes
Cheap Nike Shoes
Nike Store
Nike Running Shoes For Men
New Nike 2019
Nike Air Jordans 1
Jordan 3
Pandora Bracelet
Nike Sneakers
Yeezy 500 Utility Black
Pandora Jewelry
Golden Goose Shoes
Lebron 16 Shoes
Nike Outlet Store Online Shopping
Jordan 9
Air Jordan 7
Nike Running Shoes For Men
Louboutin Outlet
Nike Basketball Shoes
Jordan 8
Nike Cortez Women
Nike Factory Outlet
Nike Factory Outlet
Pandora Sale
Pandora Jewelry
Nike Free Run
Jordan 14
Nike Store Online
Nike Jordan 1
Nike Clearance
Nike Epic React
Christian Louboutin Shoes Outlet
Yeezy
Nike Factory Store
Moncler Outlet
Nike Running Shoes For Women
Nike Clearance Outlet
Adidas NMD
Nike Outlet Store Online Shopping
Adidas NMD
Louboutin Shoes
Jordan 4's
Nike Air Max 97
Pandora Ring
Valentino Shoes
Christian Louboutin Shoes
Pandora Charms
Adidas Yeezy
Adidas Ultra Boost
Lebron 16

Návštěvník

Re: Parsování HTML tagů z textu

Příspěvek od Návštěvník »

Nike Canada Online
Pandora Charms
Asics Sneakers
New Nike Shoes
Jordan 5
Pandora Charms
Adidas Shoes
Pandora Jewelry Official Site
Moncler Outlet Online
Ferragamo Belt
Moncler Coat
Pandora Jewelry
Pandora Black Friday
Nike Shoes Men
Asics Shoes
Adidas Shoes
Pandora Jewelry
Jordan 1s
Pandora Jewelry
Air Max 720
Air Jordan 1 High
Moncler Coats
Adidas Official Website
Pandora Outlet
Pandora
Adidas Sale
Ferragamo
Nike Air Max 97
Nike
Balenciaga
Moncler Outlet
Asics Outlet
Nike Running Shoes
Adidas Outlet
Pandora Outlet Online
Pandora Jewelry Store
Jordan Sneakers
Adidas Running Shoes For Men
Jordans 1
Nike Air Jordan 1 Retro
Pandora Charms
Pandora Jewelry
Balenciaga Sneakers
Jordan Wholesale Distributors
Adidas Sneakers Men
Pandora Bracelets
Men's Nike Shoes
Pandora Charms
Pandora
Pandora
Jordan Shoes
Pandora Jewelry Outlet
Pandora Jewelry Official Site
Pandora Charms Sale
Cheap Moncler
Jordan One
Pandora
Nike Air Jordan
Balenciaga Sneakers
Outlet Moncler
Pandora Charms
Nike Shoes For Women
Jordan 1 Retro
Nike Factory
Nike
Pandora Website
Pandora Charms Outlet
Air Jordan 1 Dior
Shoes Nike
Asics Shoes
Pandora Jewelry
Jordan 1 High
Cheap Jordan Shoes
Adidas Trainers
Nike UK
New Nike Shoes
Air Jordan 1 Retro
Nike Outlet
Goyard Handbags
Pandora
Nike Outlet Store Online Shopping
Yeezy Shoes
Air Jordan 1 Retro
Cheap Adidas
Pandora
Nike Outlet Store
Pandora Ring
Balenciaga Shoes
Jordan 1
Balenciaga Triple S
Pandora Jewelry Store
Pandora Bracelet Charms
Pandora Bracelets
Pandora Jewelry
Basketball Shoes
Balenciaga
Wholesale Jordans China
Pandora Bracelet Charms
Pandora Charm
Jordan 1 Lows
Pandora Bracelets Charms
Pandora Jewelry
Pandora Jewelry
Moncler Jackets
Salvatore Ferragamo
Nike Sneakers For Women
Pandora Jewelry 70% Off Clearance
Pandora Jewelry
Pandora Charms
Pandora Outlet
Moncler
Nike Sneakers Men
Adidas Shoes For Women
Pandora
Nike Store
Nike Shoes
Pandora Jewellery
Pandora Jewelry
Puma Shoes
Pandora Rings Official Site
Pandora Bracelet
Pandora Charms
Ferragamo Shoes Women
Goyard Bag
Nike Shoes Women
Yeezy
Asics Running Shoes Women
Pandora Bracelet
Air Jordan 1
Pandora Charms
Jordan 1 Low
Pandora Charms
Pandora Jewelry Official Site
Moncler Coats
Pandora Canada
Wholesale Jordan Shoes
Nike 270 Air Max
Pandora Jewelry Official Site
Pandora
Pandora Charms
Asics Outlet Store Online
Air Jordan 1 High
Pandora Jewelry
Asics Kayano
Ferragamo Belt Men
Air Jordan
Balenciaga
Air Max
Cheap Moncler Coats
Air Jordan 1
Moncler Jackets
Moncler Jacket
Pandora Jewelry Outlet
Nike Canada
Women Nike Shoes
Adidas Shoes Men
Adidas NMD




Návštěvník

Re: Parsování HTML tagů z textu

Příspěvek od Návštěvník »

Moncler Coat
Golden Goose Outlet
Lebron James Shoes
GGDB Shoes
Jordan 12
Moncler Vest
Cheap Jordans
Moncler Outlet
Jordan 1
Jordan 6
Pandora
Valentino Shoes
ECCO
Golden Goose Sneakers
Air Jordan 5
Adidas Yeezy
Nike Shoes
Christian Louboutin Shoes
Nike Outlet Store Online
Air Jordan
Air Jordan
Red Bottom Shoes For Women
Snkrs Nike
Pandora
Jordan 6
Adidas Yeezy
Nike Outlet
Nike Air Max 98 Cone
Nike Air Max 90 Ultra
Air Jordan
Pandora
Air Jordan 11
Vans
Jordan 4 Retro
Jordan 5 Retro
Nike Outlet Store Online Shopping
Nike Factory Outlet
Golden Goose Sneakers
Air Max 270
Huaraches Nike
Golden Gooses Sneakers
Kyrie Irving Shoes
Jordan 13
Jordan Sneakers
Nike Factory Outlet
Balenciaga Sneakers
Jordan 11
Golden Goose Outlets
Air Jordan
Retro Jordans
Soccer Shoes
Christian Louboutin UK
Air Jordan 12
Air Jordan Retro 10
Pandora Charms
Air Jordan 4
Jordan 6 Rings
Yeezy
Jordans 4
Jordan 11 Low
Nike Shoes On Sale
Jordan Retro 3
Air Force One Shoes
Jordans 11 Retro
Nike Shoes For Women
Air Jordans Shoes
Jordan Retro 1
Pandora Charms
Nike Shoes For Women
GGDB Sneakers
James Harden Shoes
Nike Factory Store
Jordan 1
Air Jordan 14
Jordan Retro 6
Pandora Jewelry
Yeezys
Adidas NMD
Red Bottoms Louboutin
Golden Goose Mid Stars
Air Jordan Shoes
Air Max 270 Women
Golden Goose Sale
Pandora Bracelets
Jordan 4
Birkin Bag
Jordan 1 Lows
Christian Louboutin Shoes
Jordan Shoes
Christian Louboutin shoes
Jordan 12
Golden Goose Shoes
Moncler Coats
Jordan 1s
Air Max
Air Jordan 1
Jordan 11's
Pandora Jewelry Official Site
Air Jordan 11
Jordan 3
Yeezy
Jordan Retro
New Jordans
Jordan 12 Retro
Christian Louboutin Heels
Yeezys
Jordan 11
Nike Jordan
Air Jordan Retro 12
Ferragamo Outlet
Pandora Rings
Jordans
Louboutin Shoes
Jordan Retro
Jordan 11's
Fitflop Shoes
Jordan Shoes For Women
Jordan Retro 11
Nike Website
Air Jordan 1
NMD
Jordan Shoes
Fjallraven Kanken
Jordan 9
Pandora Jewelry
Asics Shoes
Air Max 95
Pandora Rings
Pandora
Air Jordan 1 University Blue
Jordan 8
New Jordans
Air Jordan 4
Jordan 5
Nike Outlet Store
Jordan Sneakers
Mens Nike Shoes
Retro Jordan 11
Yeezys
Golden Goose Sneakers
Nike Shoes
Jordan 13
Moncler Jackets
Jordan Sneakers
Air Jordan 1s
Sneakers GGDB
Red Bottoms
Nike Shoes
Moncler Jackets
Air Max
Jordans Retro
Balenciaga Triple S
Jordan 11 Red
Nike Air Max

Odpovědět

Zpět na „PHP“