` tags, including those with IDs, demonstrating its structure parsing capabilities.
```HTML
Hello!
```
--------------------------------
### PHP Code Example
Source: https://github.com/dg/texy/blob/master/examples/1-2-3 start/syntax.texy
This snippet demonstrates a PHP function used within Texy! for image processing. It extracts content, alignment, and href attributes from matched patterns.
```php
function reImage($matches) {
$content = $matches[1];
$align = $matches[5];
$href = $matches[6];
}
```
--------------------------------
### Handling Self-Closing and Custom Tags
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/html-tags1b.html
Demonstrates Texy!'s support for self-closing HTML tags and custom tag structures.
```HTML
..
..
```
--------------------------------
### Handling Self-Closing and Empty Tags
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/html-tags1c.html
Demonstrates Texy!'s interpretation of self-closing tags and empty span tags.
```html
..
..
```
--------------------------------
### Basic and HTML-like Links
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/links-images.texy
Demonstrates standard hyperlink creation, including direct URLs, mailto links, and links with basic attributes. Also covers the conversion of plain text URLs and email addresses into clickable links.
```Texy!
- odkaz
pokus
- odkaz
pokus
- odkaz
prázdný
- odkaz
test prázdný
- Klasický odkaz "php Fashion":http://phpfashion.com/?
- Klasický odkaz "php Fashion":[/trine/]x
- Klasický odkaz "php Fashion .{color:blue}":[./trine/]x
- Klasický odkaz "php Fashion":[dave@example.com]x
- Klasický odkaz "php Fashion":dave@example.com
- "text1":www.text.cz
- "text1":www.text.cz)
- "text1":www.text.cz()
- "text1":www.text.cz(x)
- "text2":hxxp://test/
- "text4":mailto:dave@example.com
- "text4":mailTO:dave@example.com
- "text":#id
- "text":./xx
- "text":/xx
-
test5
-
test6
-
test7
-
test8
- www.texy.info
- www.texy.info/path, www.texy.info/path? www.texy.info/path! www.texy.info/path)
- www.texy.info/path#flag
- www.texy.info/path/#!/flag
- http://texy.info
- https://texy.info
- ftp://example.com
- ftps://example.com
- ftps://user:pass@example.com
- dave@example.com
- www.text.cz?(x)
- www.text.cz?(x)#$%10
```
--------------------------------
### PHP4 Clone Implementation
Source: https://github.com/dg/texy/blob/master/examples/syntax highlighting/sample2.texy
This PHP code snippet demonstrates how to emulate the PHP5 'clone' construct in older PHP4 versions by using an 'eval' function if 'clone' is not natively supported. It includes a basic Object class for demonstration.
```php
```
--------------------------------
### Special Characters and Entities in Texy
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/special.html
Examples of using special characters and HTML entities in Texy markup, including arrows, dashes, and mathematical symbols.
```Texy
a → b ↔ c ← d ⇒ e
Šlitr-Suchý Šlitr–Suchý
123–456
456–456
456 –456
7869– 4646
Šlitr– Suchý
Šlitr –Suchý
Šlitr – Suchý
Šlitr – Suchý
321–654–987
m−2
m2+
m2n
m2n
10±3 ±25
‘This guy's really nice.’
```
--------------------------------
### Rel Nofollow Links
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/links-images3.html
Examples of links with the 'rel="nofollow"' attribute, often used for external links to prevent SEO manipulation.
```Texy!
* relnofollow odkaz [php Fashion](http://phpfashion.com/)?
* relnofollow odkaz [php Fashion](/trine/)x
* relnofollow odkaz [php Fashion](xxx/./trine/)x
* relnofollow odkaz [php Fashion](mailto:dave@example.com)x
* relnofollow odkaz [php Fashion](mailto:dave@example.com)
* relnofollow odkaz [test1](/test)
* relnofollow odkaz [test2](mailto:test@text.cz)
* relnofollow odkaz [test3](//server/path)
* relnofollow odkaz [test4](http://server/path)
* relnofollow odkaz [test5](http://server/path)
```
--------------------------------
### Basic Image Links
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/links-images.texy
Illustrates how to embed images using various syntaxes, including direct image URLs, reference-style image definitions, and images with dimensions or alternative text.
```Texy!
- Klasický odkaz "obrazek":[* texy-big.jpg *]
- Klasický odkaz "obrazek":[* texy-big.jpg >]
- Klasický odkaz "obrazek":[*texy-big.jpg | 2 |3*]
- Referenční odkaz "obrazek":[neobrazek1]
- Referenční odkaz "obrazek":[*obrazek1*]
- Referenční odkaz "obrazek":[*obrazek3*]
- Čistě referenční odkaz [neobrazek1]
- Čistě referenční odkaz [neobrazek2]
- Čistě referenční odkaz [neobrazek3]
- Čistě referenční odkaz [neobrazek4]
- Obrázek s popiskou
------------------
[* texy.gif *]:[home] * popiska s plným formátováním
[neobrazek1]: [*texy-big.jpg | texy-big2.jpg*] text .(title)
[neobrazek2]: [* texy-big.jpg *] text
[neobrazek3]: [*texy-big.jpg*]
[neobrazek4]: [*obrazek3*] [*obrazek1*] .(test)
[*obrazek1*]: texy.jpg | texy-over.jpg .(altX)
[*obrazek2*]: texy.jpg 10x13 | texy-over.jpg
[*obrazek3*]: texy.jpg
[*obrazek4*]: texy-big.jpg
```
--------------------------------
### Rel Nofollow Links
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/links-images1.html
Examples of links with the 'rel="nofollow"' attribute, often used for external links to prevent SEO manipulation.
```Texy!
* relnofollow odkaz [php Fashion](http://phpfashion.com/)?
* relnofollow odkaz [php Fashion](/trine/)x
* relnofollow odkaz [php Fashion](xxx/./trine/)x
* relnofollow odkaz [php Fashion](mailto:dave@example.com)x
* relnofollow odkaz [php Fashion](mailto:dave@example.com)
* relnofollow odkaz [test1](/test)
* relnofollow odkaz [test2](mailto:test@text.cz)
* relnofollow odkaz [test3](//server/path)
* relnofollow odkaz [test4](http://server/path)
* relnofollow odkaz [test5](http://server/path)
```
--------------------------------
### Links with References
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/syntax.html
Shows various ways to create links using Texy!, including simple URLs, mailto links, and links with titles specified using reference syntax.
```plaintext
* Look at [Texy!](http://texy.info "this is homepage")
* My address is [me@example.com](mailto:me@example.com)
* What about [this](http://texy.info "this is homepage") site?
```
--------------------------------
### Comment Block
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
A block designated for comments. Texy! typically ignores or specially formats comment blocks.
```comment
Comment: *formátovat*
```
--------------------------------
### Indented Preformatted Text Block
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
An indented block for preformatted text. Whitespace and line breaks are preserved.
```pre
PRE: Odsazeny
text
```
--------------------------------
### Indented Default Block
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
An indented default block. Texy! maintains the indentation for the content within this block.
```default
Default: Odsazeny
text
```
--------------------------------
### Image with Reference and Alt Text
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/syntax.html
Illustrates using reference syntax for images, including alternative text for accessibility and SEO purposes.
```plaintext
What a beautiful logo  :-)
```
--------------------------------
### Ordered Lists
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/syntax.html
Illustrates how to create ordered lists using numbers followed by periods. It shows different numbering styles and list structures.
```plaintext
1. Bird
2. McHale
3. Parish
1. Bird
2. McHale
3. Parish
1. Bird
2. McHale
3. Parish
1. Bird
2. McHale
3. Parish
1. Bird
2. McHale
3. Parish
```
--------------------------------
### Block Quotes in Texy
Source: https://github.com/dg/texy/blob/master/tests/Texy/expected/special.html
Demonstrates creating block quotes with varying levels of indentation in Texy markup.
```Texy
\>>>>>
> test1
\>> test2 >>>> test3
> test4
\>> >>>>> >
> test
\>>>> test
> test
```
--------------------------------
### Indented Div Block
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
An indented block rendered as a ``. Texy! preserves the indentation within the div content.
```div
Div: Odsazeny
text
```
--------------------------------
### HTML Block with Indentation
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
Shows an indented HTML block. Texy! preserves the indentation within the HTML content.
```html
Html: Odsazeny
text
```
--------------------------------
### Reference-Style Links
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/links-images.texy
Explains how to define and use reference-style links, where the link text and URL are separated. This includes basic references, references with titles, and references with attributes.
```Texy!
- Referenční odkaz "php Fashion":[php Fashion1]
- Referenční odkaz "php Fashion":[php Fashion2]
- Referenční odkaz "php Fashion":[php Fashion3]
- Referenční odkaz "php Fashion":[email]
- Referenční odkaz "php Fashion .(title2)[bb]":[php Fashion1]?
- Referenční odkaz "php Fashion .(title2)":[php Fashion2]?
- Referenční odkaz "php Fashion":[php Fashion1#12]?
- Referenční odkaz "php Fashion":[php Fashion2?a=45]?
- Čistě referenční odkaz [php Fashion1]
- Čistě referenční odkaz [php Fashion2]
- Čistě referenční odkaz [php Fashion3]
- Čistě referenční odkaz [email]
[php Fashion1]: http://phpfashion.com/ text *o*dkazu .(title)[aa]
[php Fashion2]: /trine/ .(title)
[php Fashion3]: ./trine/
[email]: dave@example.com .(title)
```
--------------------------------
### Linking Images
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/links-images.texy
Demonstrates how to create links that use images as the clickable element. This includes standard image links and reference-style image links with associated URLs and attributes.
```Texy!
- Klasický odkaz [*texy.jpg*]:http://phpfashion.com/?
- Klasický odkaz [*texy.jpg | texy-over.jpg .(title)[class] <]:[dave@example.com]x
- Referenční odkaz [neobrazek1]:[php Fashion1]
- Referenční odkaz "php Fashion":[*obrazek2*]
- Referenční odkaz "php Fashion":[*obrazek3*]
- Referenční odkaz [*obrazek2*]:[email]
- Referenční odkaz "php Fashion .(title2)[bb]":[*obrazek2*]?
- Referenční odkaz "php Fashion .(title2)":[*obrazek3*]?
- Referenční odkaz [*obrazek1*]:[php Fashion2]
- Referenční odkaz [*obrazek2*]:[/trine/]x
- Referenční odkaz [*obrazek3<]::
- Referenční odkaz [*obrazek2>]::
- Referenční odkaz [*obrazek4*]:[*obrazek1*]
- Čistě referenční obrázek [*obrazek1*]
- Čistě referenční obrázek [*obrazek2*]
- Čistě referenční obrázek [*obrazek3*]
- Čistě referenční obrázek [*obrazek4*]
```
--------------------------------
### Div Block
Source: https://github.com/dg/texy/blob/master/tests/Texy/sources/blocks2.texy
A block that is rendered as a `
` element. Texy! allows for semantic grouping of content using block types.
```div
Div: *formátovat*
```