├── acadmia.php ├── remember.json ├── Apis ├── test.html ├── xxx.php ├── Remember.php ├── Apis.php ├── Dictionary.php ├── Youtube.php ├── OpenWeather.php ├── Google.php ├── Lyrics.php ├── Wikipedia.php ├── Schedule.php ├── Birthday.php └── birthday.json ├── simplehtmldom_1_9 ├── manual │ ├── site │ │ └── .gitkeep │ ├── docs │ │ ├── api │ │ │ ├── simple_html_dom │ │ │ │ ├── __destruct.md │ │ │ │ ├── lastChild.md │ │ │ │ ├── firstChild.md │ │ │ │ ├── loadFile.md │ │ │ │ ├── __toString.md │ │ │ │ ├── remove_callback.md │ │ │ │ ├── parse.md │ │ │ │ ├── clear.md │ │ │ │ ├── createTextNode.md │ │ │ │ ├── load_file.md │ │ │ │ ├── read_tag.md │ │ │ │ ├── childNodes.md │ │ │ │ ├── as_text_node.md │ │ │ │ ├── getElementById.md │ │ │ │ ├── save.md │ │ │ │ ├── createElement.md │ │ │ │ ├── getElementByTagName.md │ │ │ │ ├── dump.md │ │ │ │ ├── search_noise.md │ │ │ │ ├── skip.md │ │ │ │ ├── link_nodes.md │ │ │ │ ├── getElementsById.md │ │ │ │ ├── set_callback.md │ │ │ │ ├── getElementsByTagName.md │ │ │ │ ├── copy_skip.md │ │ │ │ ├── copy_until_char.md │ │ │ │ ├── copy_until.md │ │ │ │ ├── restore_noise.md │ │ │ │ ├── find.md │ │ │ │ ├── parse_attr.md │ │ │ │ ├── parse_charset.md │ │ │ │ ├── prepare.md │ │ │ │ ├── __get.md │ │ │ │ ├── remove_noise.md │ │ │ │ ├── load.md │ │ │ │ ├── __construct.md │ │ │ │ └── simple_html_dom.md │ │ │ ├── simple_html_dom_node │ │ │ │ ├── parentNode.md │ │ │ │ ├── __destruct.md │ │ │ │ ├── makeup.md │ │ │ │ ├── __toString.md │ │ │ │ ├── nodeName.md │ │ │ │ ├── clear.md │ │ │ │ ├── lastChild.md │ │ │ │ ├── has_child.md │ │ │ │ ├── text.md │ │ │ │ ├── getAllAttributes.md │ │ │ │ ├── nextSibling.md │ │ │ │ ├── firstChild.md │ │ │ │ ├── __unset.md │ │ │ │ ├── hasChildNodes.md │ │ │ │ ├── prevSibling.md │ │ │ │ ├── xmltext.md │ │ │ │ ├── innertext.md │ │ │ │ ├── last_child.md │ │ │ │ ├── outertext.md │ │ │ │ ├── first_child.md │ │ │ │ ├── next_sibling.md │ │ │ │ ├── prev_sibling.md │ │ │ │ ├── getAttribute.md │ │ │ │ ├── getElementById.md │ │ │ │ ├── is_utf8.md │ │ │ │ ├── get_display_size.md │ │ │ │ ├── getElementByTagName.md │ │ │ │ ├── hasAttribute.md │ │ │ │ ├── removeAttribute.md │ │ │ │ ├── children.md │ │ │ │ ├── setAttribute.md │ │ │ │ ├── find_ancestor_tag.md │ │ │ │ ├── dump_node.md │ │ │ │ ├── parse_selector.md │ │ │ │ ├── hasClass.md │ │ │ │ ├── appendChild.md │ │ │ │ ├── dump.md │ │ │ │ ├── getElementsById.md │ │ │ │ ├── childNodes.md │ │ │ │ ├── __construct.md │ │ │ │ ├── getElementsByTagName.md │ │ │ │ ├── parent.md │ │ │ │ ├── save.md │ │ │ │ ├── convert_text.md │ │ │ │ ├── match.md │ │ │ │ ├── addClass.md │ │ │ │ ├── __set.md │ │ │ │ ├── seek.md │ │ │ │ ├── remove.md │ │ │ │ ├── removeClass.md │ │ │ │ ├── __isset.md │ │ │ │ ├── removeChild.md │ │ │ │ ├── simple_html_dom_node.md │ │ │ │ ├── __get.md │ │ │ │ └── find.md │ │ │ ├── constants.md │ │ │ ├── str_get_html.md │ │ │ ├── file_get_html.md │ │ │ ├── api.md │ │ │ └── definitions.md │ │ ├── manual │ │ │ ├── saving-dom-objects.md │ │ │ ├── customizing-parsing-behavior.md │ │ │ ├── creating-dom-objects.md │ │ │ ├── traversing-dom-tree.md │ │ │ ├── accessing-element-attributes.md │ │ │ ├── finding-html-elements.md │ │ │ └── adding-nodes.md │ │ ├── requirements.md │ │ ├── index.md │ │ ├── faq.md │ │ └── quick-start.md │ ├── extra.css │ ├── custom_theme │ │ └── main.html │ ├── README.md │ └── mkdocs.yml ├── example │ ├── example_extract_html.php │ ├── example_modify_contents.php │ ├── example_callback.php │ ├── scraping │ │ ├── example_scraping_slashdot.php │ │ ├── example_scraping_digg.php │ │ ├── example_scraping_imdb.php │ │ └── example_scraping_general.php │ ├── simple_html_dom_utility.php │ ├── example_basic_selector.php │ └── example_advanced_selector.php ├── phpcompatibility.xml ├── LICENSE ├── phpcs.xml └── CHANGELOG.md ├── Bot.zip ├── Bot13.zip ├── Bot22.zip ├── Bot31.zip ├── README.md ├── jsmodules ├── soundChip.js ├── chip.js └── text to speech.js ├── user.json ├── modules ├── randomQuery.php └── analyzeQuery.php ├── google.php ├── category.json ├── Sample.json ├── people.json ├── statement.json ├── getLyrics.php ├── randomChats.json ├── bot1.js ├── bot.php ├── utilities.php ├── ai.json ├── index.html ├── data.json ├── schedule.json ├── academia.html ├── birthdayFormat.json └── birthday.json /acadmia.php: -------------------------------------------------------------------------------- 1 | plaintext; 5 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/__destruct.md: -------------------------------------------------------------------------------- 1 | # __destruct 2 | 3 | ```php 4 | __destruct () 5 | ``` 6 | 7 | Destroys the current object and clears memory. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/extra.css: -------------------------------------------------------------------------------- 1 | code { 2 | white-space: nowrap; 3 | } 4 | 5 | .logo { 6 | display: block; 7 | margin: auto; 8 | text-align: center; 9 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/lastChild.md: -------------------------------------------------------------------------------- 1 | # lastChild 2 | 3 | ```php 4 | lastChild () : object 5 | ``` 6 | 7 | Returns the last child of the root element. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/parentNode.md: -------------------------------------------------------------------------------- 1 | # parentNode 2 | 3 | ```php 4 | parentNode () : object 5 | ``` 6 | 7 | Returns the current's node parent. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/firstChild.md: -------------------------------------------------------------------------------- 1 | # firstChild 2 | 3 | ```php 4 | firstChild () : object 5 | ``` 6 | 7 | Returns the first child of the root element. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/loadFile.md: -------------------------------------------------------------------------------- 1 | # loadFile 2 | 3 | ```php 4 | loadFile (...) 5 | ``` 6 | 7 | This function is a wrapper for [`load_file`](#load_file) -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__destruct.md: -------------------------------------------------------------------------------- 1 | # __destruct 2 | 3 | ```php 4 | __destruct ( ) 5 | ``` 6 | 7 | Destructs the current object and frees memory. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/makeup.md: -------------------------------------------------------------------------------- 1 | # makeup 2 | 3 | ```php 4 | makeup ( ) : string 5 | ``` 6 | 7 | Returns the HTML representation of the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__toString.md: -------------------------------------------------------------------------------- 1 | # __toString 2 | 3 | ```php 4 | __toString ( ) : string 5 | ``` 6 | 7 | Returns the outer text of the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/nodeName.md: -------------------------------------------------------------------------------- 1 | # nodeName 2 | 3 | ```php 4 | nodeName ( ) : string 5 | ``` 6 | 7 | Returns the name of the current node (tag name). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/__toString.md: -------------------------------------------------------------------------------- 1 | # __toString 2 | 3 | ```php 4 | __toString () : string 5 | ``` 6 | 7 | Returns the inner text of the root element of the DOM. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/clear.md: -------------------------------------------------------------------------------- 1 | # clear 2 | 3 | ```php 4 | clear ( ) 5 | ``` 6 | 7 | Sets all properties in the current node, which contain objects, to null. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/lastChild.md: -------------------------------------------------------------------------------- 1 | # lastChild 2 | 3 | ```php 4 | lastChild ( ) : object 5 | ``` 6 | 7 | This is a wrapper for [`last_child`](../last_child/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/has_child.md: -------------------------------------------------------------------------------- 1 | # has_child 2 | 3 | ```php 4 | has_child ( ) : bool 5 | ``` 6 | 7 | Returns true if the current node has one or more child nodes. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/text.md: -------------------------------------------------------------------------------- 1 | # text 2 | 3 | ```php 4 | text ( ) : string 5 | ``` 6 | 7 | Returns the (HTML) text representation for the current node recursively. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/remove_callback.md: -------------------------------------------------------------------------------- 1 | # remove_callback 2 | 3 | ```php 4 | remove_callback () 5 | ``` 6 | 7 | Removes the callback set by [`set_callback`](#set_callback). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getAllAttributes.md: -------------------------------------------------------------------------------- 1 | # getAllAttributes 2 | 3 | ```php 4 | getAllAttributes ( ) : array 5 | ``` 6 | 7 | Returns all attributes for the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/nextSibling.md: -------------------------------------------------------------------------------- 1 | # nextSibling 2 | 3 | ```php 4 | nextSibling ( ) : object 5 | ``` 6 | 7 | This is a wrapper for [`next_sibling`](../next_sibling/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/firstChild.md: -------------------------------------------------------------------------------- 1 | # firstChild 2 | 3 | ```php 4 | firstChild ( ) : mixed 5 | ``` 6 | 7 | This function is a wrapper for [`first_child`](../first_child/) -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__unset.md: -------------------------------------------------------------------------------- 1 | # __unset 2 | 3 | ```php 4 | __unset ( string $name ) 5 | ``` 6 | 7 | Removes the attribute with name `$name` from the current node if it exists. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/hasChildNodes.md: -------------------------------------------------------------------------------- 1 | # hasChildNodes 2 | 3 | ```php 4 | hasChildNodes ( ) : bool 5 | ``` 6 | 7 | This is a wrapper function for [`has_child`](../has_child/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/prevSibling.md: -------------------------------------------------------------------------------- 1 | # prevSibling 2 | 3 | ```php 4 | prevSibling ( ) : object 5 | ``` 6 | 7 | This is a wrapper for [`previous_sibling`](../previous_sibling/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/parse.md: -------------------------------------------------------------------------------- 1 | # parse (protected) 2 | 3 | ```php 4 | parse () 5 | ``` 6 | 7 | Parses the document. This function is called after the document was loaded into `$this->doc`. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/clear.md: -------------------------------------------------------------------------------- 1 | # clear 2 | 3 | ```php 4 | clear () 5 | ``` 6 | 7 | Cleans up memory to prevent [PHP 5 circular references memory leak](https://bugs.php.net/bug.php?id=33595). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/createTextNode.md: -------------------------------------------------------------------------------- 1 | # createTextNode 2 | 3 | ```php 4 | createTextNode ( string $value ) : object 5 | ``` 6 | 7 | Creates a new text element. 8 | 9 | Returns the element. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/xmltext.md: -------------------------------------------------------------------------------- 1 | # xmltext 2 | 3 | ```php 4 | xmltext ( ) : string 5 | ``` 6 | 7 | Returns the xml representation for the inner text of the current node as a CDATA section. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/innertext.md: -------------------------------------------------------------------------------- 1 | # innertext 2 | 3 | ```php 4 | innertext ( ) : string 5 | ``` 6 | 7 | Returns the inner text (everything inside the opening and closing tags) of the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/last_child.md: -------------------------------------------------------------------------------- 1 | # last_child 2 | 3 | ```php 4 | last_child ( ) : object 5 | ``` 6 | 7 | Returns the last child of the current node or null if the current node has no child elements. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/outertext.md: -------------------------------------------------------------------------------- 1 | # outertext 2 | 3 | ```php 4 | outertext ( ) : string 5 | ``` 6 | 7 | Returns the outer text (everything including the opening and closing tags) of the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/first_child.md: -------------------------------------------------------------------------------- 1 | # first_child 2 | 3 | ```php 4 | first_child ( ) : mixed 5 | ``` 6 | 7 | Returns the first child node of the current node or null if the current nod has no child nodes. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/next_sibling.md: -------------------------------------------------------------------------------- 1 | # next_sibling 2 | 3 | ```php 4 | next_sibling ( ) : object 5 | ``` 6 | 7 | Returns the next sibling of the current node or null if the current node has no next sibling. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/prev_sibling.md: -------------------------------------------------------------------------------- 1 | # prev_sibling 2 | 3 | ```php 4 | prev_sibling ( ) : object 5 | ``` 6 | 7 | Returns the previous sibling of the current node, or null if the current node has no previous sibling. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/load_file.md: -------------------------------------------------------------------------------- 1 | # load_file 2 | 3 | ```php 4 | load_file (...) : object 5 | ``` 6 | 7 | Loads a HTML document from file. Supports arguments of [`file_get_contents`](http://php.net/manual/en/function.file-get-contents.php). 8 | 9 | Returns the object. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/read_tag.md: -------------------------------------------------------------------------------- 1 | # read_tag (protected) 2 | 3 | ```php 4 | read_tag () : bool 5 | ``` 6 | 7 | Reads a single tag starting at the current parsing position in the document. The tag is automatically added to the DOM. 8 | 9 | Returns true if a tag was found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getAttribute.md: -------------------------------------------------------------------------------- 1 | # getAttribute 2 | 3 | ```php 4 | getAttribute ( string $name ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Attribute name. 10 | 11 | Returns the value for the attribute `$name`. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/childNodes.md: -------------------------------------------------------------------------------- 1 | # childNodes 2 | 3 | ```php 4 | childNodes ( [ int $idx = -1 ] ) : mixed 5 | ``` 6 | 7 | Returns children of the root element. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `idx` | Index of the child element to return. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getElementById.md: -------------------------------------------------------------------------------- 1 | # getElementById 2 | 3 | ```php 4 | getElementById ( string $id ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `id` | Element id. 10 | 11 | Returns the first element with the specified id. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/is_utf8.md: -------------------------------------------------------------------------------- 1 | # is_utf8 (static) 2 | 3 | ```php 4 | is_utf8 ( string $str ) : bool 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `str` | String to test. 10 | 11 | Returns true if the provided string is a valid UTF-8 string. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/get_display_size.md: -------------------------------------------------------------------------------- 1 | # get_display_size 2 | 3 | ```php 4 | get_display_size ( ) : mixed 5 | ``` 6 | 7 | Returns false if the current node is not an image. 8 | 9 | Returns an associative array of two elements - `height` and `width` - that represent the display size of the image. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/as_text_node.md: -------------------------------------------------------------------------------- 1 | # as_text_node (protected) 2 | 3 | ```php 4 | as_text_node ( string $tag ) : bool 5 | ``` 6 | 7 | Adds a tag as text node. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `tag` | The element's tag name. 12 | 13 | Returns true on success. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getElementByTagName.md: -------------------------------------------------------------------------------- 1 | # getElementByTagName 2 | 3 | ```php 4 | getElementByTagName ( string $name ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Tag name. 10 | 11 | Returns the first element with the specified tag name. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/custom_theme/main.html: -------------------------------------------------------------------------------- 1 | {% extends "base.html" %} 2 | 3 | {% block footer %} 4 | {% include "footer.html" %} 5 |
6 | 7 | {% endblock %} -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/hasAttribute.md: -------------------------------------------------------------------------------- 1 | # hasAttribute 2 | 3 | ```php 4 | hasAttribute ( string $name ) : bool 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Name of the attribute. 10 | 11 | Returns true if the current node has an attribute with the specified name. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/removeAttribute.md: -------------------------------------------------------------------------------- 1 | # removeAttribute 2 | 3 | ```php 4 | removeAttribute ( string $name ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Name of the attribute to remove. 10 | 11 | Removes the attribute with the speicified name from the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/getElementById.md: -------------------------------------------------------------------------------- 1 | # getElementById 2 | 3 | ```php 4 | getElementById ( string $id ) : object 5 | ``` 6 | 7 | Searches an element by id. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `id` | ID of the element to find. 12 | 13 | Returns the element or null if no match was found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/children.md: -------------------------------------------------------------------------------- 1 | # children 2 | 3 | ```php 4 | children ( [ int $idx = -1 ] ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `idx` | Index of the node to return or `-1` to return all nodes. 10 | 11 | Returns all or one specific child node from the current node. 12 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/save.md: -------------------------------------------------------------------------------- 1 | # save 2 | 3 | ```php 4 | save ( [ string $filepath = '' ] ) : string 5 | ``` 6 | 7 | Writes the current DOM to file. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `filepath` | Writes to file if the provided file path is not empty. 12 | 13 | Returns the document string. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/setAttribute.md: -------------------------------------------------------------------------------- 1 | # setAttribute 2 | 3 | ```php 4 | setAttribute ( string $name, string $value ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Attribute name 10 | | `value` | Attribute value 11 | 12 | Adds or sets an attribute in the current node to the specified value. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/createElement.md: -------------------------------------------------------------------------------- 1 | # createElement 2 | 3 | ```php 4 | createElement ( string $name [, string $value = null ] ) : object 5 | ``` 6 | 7 | Creates a new element. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `name` | Name of the element 12 | | `value` | Value of the element 13 | 14 | Returns the element. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/getElementByTagName.md: -------------------------------------------------------------------------------- 1 | # getElementByTagName 2 | 3 | ```php 4 | getElementByTagName ( string $name ) : object 5 | ``` 6 | 7 | Searches an element by tag name. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `name` | Tag name of the element to find. 12 | 13 | Returns the element or null if no match was found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/find_ancestor_tag.md: -------------------------------------------------------------------------------- 1 | # find_ancestor_tag 2 | 3 | ```php 4 | find_ancestor_tag ( string $tag ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `tag` | Tag name of the element to find. 10 | 11 | Returns the first matching node that matches the specified tag name or null if no match was found. -------------------------------------------------------------------------------- /jsmodules/soundChip.js: -------------------------------------------------------------------------------- 1 | function soundChip(videoId, videoTitle) { 2 | chip(`Playing ${videoTitle}`, 0, 1) 3 | document.getElementById("youtube").innerHTML = `
4 |
` 7 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/dump.md: -------------------------------------------------------------------------------- 1 | # dump 2 | 3 | ```php 4 | dump ( [ bool show_attr = true ] ) : string 5 | ``` 6 | 7 | Dumps the entire DOM into a string. Useful for debugging purposes. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `show_attr` | Attributes are included in the dump when enabled. 12 | 13 | Returns the DOM tree as string. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/dump_node.md: -------------------------------------------------------------------------------- 1 | # dump_node 2 | 3 | ```php 4 | dump_node ( [ bool $echo = true ] ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `echo` | Echoes the dump details directly if enabled. 10 | 11 | Dumps information about the current document node. Returns a string if `$echo` is set to false, null otherwise. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/parse_selector.md: -------------------------------------------------------------------------------- 1 | # parse_selector (protected) 2 | 3 | ```php 4 | parse_selector ( string $selector_string ) : array 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `selector_string` | The selector string 10 | 11 | Parses a CSS selector into an internal format for further use. See also [`find`](../find/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/search_noise.md: -------------------------------------------------------------------------------- 1 | # search_noise (protected) 2 | 3 | ```php 4 | search_noise ( string $text ) : string 5 | ``` 6 | 7 | Find a single noise element by providing the noise placeholder text. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `text` | The noise placeholder to find. 12 | 13 | Returns the original contents for the placeholder. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/hasClass.md: -------------------------------------------------------------------------------- 1 | # hasClass 2 | 3 | ```php 4 | hasClass ( string $class ) : bool 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `class` | Specifies the class name to search for. 10 | 11 | Returns true if the current node has the specified class name. 12 | 13 | **Examples** 14 | 15 | ```php 16 | $node->hasClass('article'); 17 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/skip.md: -------------------------------------------------------------------------------- 1 | 2 | # skip (protected) 3 | 4 | ```php 5 | skip ( string $chars ) 6 | ``` 7 | 8 | Skips characters starting at the current parsing position in the document. Sets the parsing position to the first character not in the provided list of characters. 9 | 10 | | Parameter | Description 11 | | --------- | ----------- 12 | | `chars` | A list of characters to skip. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/appendChild.md: -------------------------------------------------------------------------------- 1 | # appendChild 2 | 3 | ```php 4 | appendChild ( object $node ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `node` | An object of type [`simple_html_dom_node`](../simple_html_dom_node/) 10 | 11 | Makes the current node parent of the node provided to this function. 12 | 13 | Returns the provided node. 14 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/link_nodes.md: -------------------------------------------------------------------------------- 1 | # link_nodes (protected) 2 | 3 | ```php 4 | link_nodes ( object &$node, bool $is_child ) 5 | ``` 6 | 7 | Links the provided node to the DOM tree. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `node` | The node to link to the DOM tree. 12 | | `is_child` | If active, makes the node a sibling of the current node (child of parent). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/dump.md: -------------------------------------------------------------------------------- 1 | # dump 2 | 3 | ```php 4 | dump ( [ bool $show_attr = false [, int $depth = 0 ]] ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `show_attr` | Attribute names are included in the output if enabled. 10 | | `depth` | Depth of the current element 11 | 12 | Dumps information about the current node and all child nodes recursively. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getElementsById.md: -------------------------------------------------------------------------------- 1 | # getElementsById 2 | 3 | ```php 4 | getElementsById ( string $id [, int $idx = null] ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `id` | Element id. 10 | | `idx` | Index of element to return. 11 | 12 | Returns all elements with the specified id if `$idx` is null, or a specific one if `$idx` is a valid index. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/childNodes.md: -------------------------------------------------------------------------------- 1 | # childNodes 2 | 3 | ```php 4 | childNodes ( [ int $idx = -1 ] ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `idx` | Index of the node to return or `-1` to return all nodes. 10 | 11 | Returns all or one specific child node from the current node. 12 | 13 | ## Remarks 14 | 15 | This function is a wrapper for [`children`](../children/) -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/getElementsById.md: -------------------------------------------------------------------------------- 1 | # getElementsById 2 | 3 | ```php 4 | getElementsById ( string $id [, int $idx = null ] ) : object 5 | ``` 6 | 7 | Searches elements by id. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `id` | ID of the element to find. 12 | | `idx` | Returns the element at the specified index if defined. 13 | 14 | Returns the element(s) or null if no match was found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__construct.md: -------------------------------------------------------------------------------- 1 | # __construct 2 | 3 | ```php 4 | __construct ( [ object $dom ] ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `dom` | An object of type [`simple_html_dom`](api/simple_html_dom/). 10 | 11 | Constructs a new object of type `simple_html_dom_node`, assignes `$dom` as DOM object and adds itself to the list of nodes in `$dom`. 12 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/set_callback.md: -------------------------------------------------------------------------------- 1 | # set_callback 2 | 3 | ```php 4 | set_callback ( string $function_name ) 5 | ``` 6 | 7 | Sets the callback function which is called on each element of the DOM when building outertext. 8 | The function must accept a single parameter of type `simple_html_dom_node`. 9 | 10 | | Parameter | Description 11 | | --------- | ----------- 12 | | `function_name` | Name of the function. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/getElementsByTagName.md: -------------------------------------------------------------------------------- 1 | # getElementsByTagName 2 | 3 | ```php 4 | getElementsByTagName ( string $name [, int $idx = null ] ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | Tag name. 10 | | `idx` | Index of the element to return. 11 | 12 | Returns all elements with the specified tag name if `$idx` is null, or a specific one if `$idx` is a valid index. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/getElementsByTagName.md: -------------------------------------------------------------------------------- 1 | # getElementsByTagName 2 | 3 | ```php 4 | getElementsByTagName ( string $name [, int $idx = -1 ] ) : object 5 | ``` 6 | 7 | Searches elements by tag name. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `name` | Tag name of the element to find. 12 | | `idx` | Returns the element at the specified index. 13 | 14 | Returns the element(s) or null if no match was found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/copy_skip.md: -------------------------------------------------------------------------------- 1 | # copy_skip (protected) 2 | 3 | ```php 4 | copy_skip ( string $chars ) : string 5 | ``` 6 | 7 | Skips characters starting at the current parsing position in the document. Sets the parsing position to the first character not in the provided list of characters. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `chars` | A list of characters to skip. 12 | 13 | Returns the skipped characters. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/saving-dom-objects.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Saving DOM objects 3 | --- 4 | 5 | # Functional 6 | 7 | ```php 8 | // Dumps the internal DOM tree back into string 9 | $str = $html; 10 | 11 | // Print it! 12 | echo $html; 13 | ``` 14 | 15 | # Object Oriented 16 | 17 | ```php 18 | // Dumps the internal DOM tree back into string 19 | $str = $html->save(); 20 | 21 | // Dumps the internal DOM tree back into a file 22 | $html->save('result.htm'); 23 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/example_modify_contents.php: -------------------------------------------------------------------------------- 1 | find('img') as $e) 10 | $e->outertext = ''; 11 | 12 | // replace all input 13 | foreach($html->find('input') as $e) 14 | $e->outertext = '[INPUT]'; 15 | 16 | // dump contents 17 | echo $html; 18 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/parent.md: -------------------------------------------------------------------------------- 1 | # parent 2 | 3 | ```php 4 | parent ( [ object $parent = null ] ) : object 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `parent` | The parent node 10 | 11 | * Returns the parent node of the current node if `$parent` is null. 12 | * Sets the parent node of the current node if `$parent` is not null. In this case the current node is automatically added to the list of nodes in the parent node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/save.md: -------------------------------------------------------------------------------- 1 | # save 2 | 3 | ```php 4 | save ( [ string $filepath = '' ] ) : string 5 | ``` 6 | 7 | Writes the current node to file. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `filepath` | Writes to file if the provided file path is not empty. 12 | 13 | Returns the document string. 14 | 15 | **Examples** 16 | 17 | ```php 18 | $string = $node->save(); 19 | $string = $node->save($file); 20 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/copy_until_char.md: -------------------------------------------------------------------------------- 1 | # copy_until_char (protected) 2 | 3 | ```php 4 | copy_until ( string $char ) : string 5 | ``` 6 | 7 | Copies all characters starting at the current parsing position in the document. Sets the parsing position to the first character that matches the provided character. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `char` | A character to stop copying at. 12 | 13 | Returns the copied characters. -------------------------------------------------------------------------------- /user.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Hi, Raghav", 3 | "height": "I know you're 170cm tall", 4 | "weight": "You are 61 kilograms", 5 | "nationality": "Indian", 6 | "college": "You study in SRM Chennai", 7 | "euphoria": "I won't tell", 8 | "girlfriend": "Noone can see her. By the way you don't need any girl, you have me", 9 | "phone number": "It's 6387658003", 10 | "email": "It's raghavseries572@gmail.com", 11 | "birthplace": "You're mother told me that you were born in Lucknow{|🙂|}" 12 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/copy_until.md: -------------------------------------------------------------------------------- 1 | # copy_until (protected) 2 | 3 | ```php 4 | copy_until ( string $chars ) : string 5 | ``` 6 | 7 | Copies all characters starting at the current parsing position in the document. Sets the parsing position to the first character that matches any of the characters in the provided list of characters. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `chars` | A list of characters to stop copying at. 12 | 13 | Returns the copied characters. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/restore_noise.md: -------------------------------------------------------------------------------- 1 | # restore_noise (protected) 2 | 3 | ```php 4 | restore_noise ( string $text ) : string 5 | ``` 6 | 7 | Restores noise in the provided string by replacing noise placeholders by their original contents. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `text` | A string (potentially) containing noise placeholders. 12 | 13 | Returns the string with original contents restored or the original string if it doesn't contain noise placeholders. -------------------------------------------------------------------------------- /modules/randomQuery.php: -------------------------------------------------------------------------------- 1 | result = $reply; 13 | return json_encode($obj);; 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/phpcompatibility.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Defines rules for PHPCompatibility 4 | ./app 5 | ./example 6 | ./manual 7 | ./testcase 8 | ./tests 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/convert_text.md: -------------------------------------------------------------------------------- 1 | # convert_text 2 | 3 | ```php 4 | convert_text ( string $text ) : string 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `text` | Text to convert. 10 | 11 | Assumes that the provided text is in the form of the configured source character set (see [`sourceCharset`](../simple_html_dom_node/) and converts it to the specified target character set (see [`targetCharset`](../simple_html_dom_node/)). 12 | 13 | Returns the converted text. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/customizing-parsing-behavior.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Customizing Parsing behavior 3 | --- 4 | 5 | ```php 6 | // Write a function with parameter "$element" 7 | function my_callback($element) { 8 | // Hide all tags 9 | if ($element->tag=='b') 10 | $element->outertext = ''; 11 | } 12 | 13 | // Register the callback function with it's function name 14 | $html->set_callback('my_callback'); 15 | 16 | // Callback function will be invoked while dumping 17 | echo $html; 18 | ``` -------------------------------------------------------------------------------- /Apis/Apis.php: -------------------------------------------------------------------------------- 1 | useApi($str); 11 | break; 12 | } 13 | else break; 14 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/find.md: -------------------------------------------------------------------------------- 1 | # find 2 | 3 | ```php 4 | find ( string $selector [, int $idx = null [, bool $lowercase = false ]] ) : mixed 5 | ``` 6 | 7 | Finds elements in the DOM. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `selector` | A [CSS style selector](/manual/selectors). 12 | | `idx` | Index of the element to return. 13 | | `lowercase` | Matches tag names case insensitive when enabled. 14 | 15 | Returns an array of matches or a single element if `idx` is defined. -------------------------------------------------------------------------------- /google.php: -------------------------------------------------------------------------------- 1 | '); 7 | $results = str_replace("...", "
", strip_tags(substr($html, $st+8, strlen($html)))); 8 | 9 | if(strpos($results, "http") > -1) 10 | $results = substr($results, 0, strpos($results, "http")); 11 | if(strpos($results, "More items") > -1) 12 | $results = substr($results, 0, strpos($results, "More items")); 13 | echo $results; 14 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/parse_attr.md: -------------------------------------------------------------------------------- 1 | # parse_attr (protected) 2 | 3 | ```php 4 | parse_attr ( object $node, string $name, array &$space ) 5 | ``` 6 | 7 | Parses a single attribute starting at the current parsing position in the document. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `node` | The current element (node). 12 | | `name` | The attribute name. 13 | | `space` | An array of whitespace sorounding the current attribute (see [Attribute Whitespace](../definitions/#attribute-whitespace)). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/match.md: -------------------------------------------------------------------------------- 1 | # match (protected) 2 | 3 | ```php 4 | match ( 5 | string $exp 6 | , string $pattern 7 | , string $value 8 | , string $case_sensitivity 9 | ) : bool 10 | ``` 11 | 12 | | Parameter | Description 13 | | --------- | ----------- 14 | | `exp` | Expression 15 | | `pattern` | Pattern 16 | | `value` | Value 17 | | `case_sensitivity` | Case sensitivity 18 | 19 | Matches a single attribute value against the specified attribute selector. See also [`find`](../find/). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/addClass.md: -------------------------------------------------------------------------------- 1 | # addClass 2 | 3 | ```php 4 | addClass ( mixed $class ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `class` | Specifies one or more class names to be added. 10 | 11 | Adds one or more class names to the current node. 12 | 13 | **Remarks** 14 | 15 | * To add more than one class, separate the class names with space or provide them as an array. 16 | 17 | **Examples** 18 | 19 | ```php 20 | $node->addClass('hidden'); 21 | $node->addClass('article important'); 22 | $node->addClass(array('article', 'new')); 23 | ``` -------------------------------------------------------------------------------- /category.json: -------------------------------------------------------------------------------- 1 | { 2 | "apis":{ 3 | "apisName":["Wikipedia", "OpenWeather", "Lyrics", "Schedule", "Birthday", "Dictionary", "Youtube","Remember", "Google"], 4 | "apisKws": { 5 | "0": ["search"], 6 | "1": ["weather"], 7 | "2": ["lyrics"], 8 | "3": ["timetable", "schedule", "mess", "pf", "mano", "manoranjitham"], 9 | "4": ["birthday", "birthdays"], 10 | "5": ["meaning", "definition"], 11 | "6": ["play", "play song"], 12 | "7": ["remember"], 13 | "8": ["google", "how to"] 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/parse_charset.md: -------------------------------------------------------------------------------- 1 | # parse_charset (protected) 2 | 3 | ```php 4 | parse_charset () 5 | ``` 6 | 7 | Parses the charset. 8 | 9 | If the callback function `get_last_retrieve_url_contents_content_type` exists, it is assumed to return the content type header for the current document as string. 10 | 11 | Uses the charset from the metadata of the page if defined. 12 | 13 | If none of the previous conditions are met, the charset is determined by `mb_detect_encoding` if multi-byte support is active. 14 | 15 | If multi-byte support is not active the charset is assumed to be `'UTF-8'`. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/prepare.md: -------------------------------------------------------------------------------- 1 | # prepare (protected) 2 | 3 | ```php 4 | prepare ( string $str [, bool $lowercase = true [, string $defaultBRText = DEFAULT_BR_TEXT [, string $defaultSpanText = DEFAULT_SPAN_TEXT ]]] ) 5 | ``` 6 | 7 | Initializes the DOM object. 8 | 9 | | Parameters | Description 10 | | ---------- | ----------- 11 | | `str` | The HTML document string. 12 | | `lowercase` | Tag names are parsed in lowercase letters if enabled. 13 | | `defaultBRText` | Defines the default text to return for `
` elements. 14 | | `defaultSpanText` | Defines the default text to return for `` elements. -------------------------------------------------------------------------------- /Apis/Dictionary.php: -------------------------------------------------------------------------------- 1 | '); 10 | $meaning = substr($htm, $start+34, $end-$start-35); 11 | $meaning = chopStrs($meaning, ['See more.">']); 12 | $obj = new Class{}; 13 | $obj->result = $meaning; 14 | return json_encode($obj); 15 | } 16 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__set.md: -------------------------------------------------------------------------------- 1 | # __set 2 | 3 | ```php 4 | __set ( string $name, mixed $value ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | `outertext`, `innertext` or attribute name. 10 | | `value` | Value to set. 11 | 12 | See [magic methods](http://php.net/manual/en/language.oop5.overloading.php#object.get) 13 | 14 | Sets the outer text of the current node to `$value` if `$name` is `outertext`. 15 | 16 | Sets the inner text of the current node to `$value` if `$name` is `innertext`. 17 | 18 | Otherwise, adds or updates an attribute with name `$name` and value `$value` to the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/__get.md: -------------------------------------------------------------------------------- 1 | # __get 2 | 3 | ```php 4 | __get ( string $name ) : mixed 5 | ``` 6 | 7 | See [magic methods](http://php.net/manual/en/language.oop5.overloading.php#object.get) 8 | 9 | Supports following names: 10 | 11 | | Name | Description 12 | | ---- | ----------- 13 | | `outertext` | Returns the outer text of the root element. 14 | | `innertext` | Returns the inner text of the root element. 15 | | `plaintext` | Returns the plain text of the root element. 16 | | `charset` | Returns the charset for the document. 17 | | `target_charset` | Returns the target charset for the document. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/requirements.md: -------------------------------------------------------------------------------- 1 | | Requirement | Minimum | Recommended | 2 | | ----------- |:-------:|:-----------: | 3 | | PHP Version | 5.6.0 | [Latest stable release](https://www.php.net/supported-versions.php) | 4 | | PHP Extensions | [iconv](https://www.php.net/manual/en/book.iconv.php) | [iconv](https://www.php.net/manual/en/book.iconv.php),
[mbstring](https://www.php.net/manual/en/book.mbstring.php) 5 | | PHP INI Settings | --- | [allow_url_fopen = 1](https://www.php.net/manual/en/filesystem.configuration.php#ini.allow-url-fopen) ** 6 | 7 | ** This makes it possible to load files from URL using [`file_get_html`](/api/file_get_html/) -------------------------------------------------------------------------------- /Apis/Youtube.php: -------------------------------------------------------------------------------- 1 | videoTitle = $data["items"][0]["snippet"]["title"]; 9 | $obj->videoTitle = str_replace("'", "'", $obj->videoTitle); 10 | $obj->videoTitle = str_replace("(", "{|(", $obj->videoTitle); 11 | $obj->videoTitle = str_replace(")", ")|}", $obj->videoTitle); 12 | $obj->videoId = $data["items"][0]["id"]["videoId"]; 13 | $json = json_encode($obj); 14 | return $json; 15 | } 16 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/seek.md: -------------------------------------------------------------------------------- 1 | # seek (protected) 2 | 3 | ```php 4 | seek ( 5 | string $selector 6 | , array &$ret 7 | , string $parent_cmd 8 | [, bool $lowercase = false ] 9 | ) 10 | ``` 11 | 12 | | Parameter | Description 13 | | --------- | ----------- 14 | | `selector` | The current selector. 15 | | `ret` | Previous return value (starting point). 16 | | `parent_cmd` | The combinator used before the current selector. 17 | | `lowercase` | Matches tag names case insensitive (lowercase) if enabled. 18 | 19 | Starts by searching for child elements of `$ret` that match the specified selector. Adds matching elements to `$ret` (for the next iteration). -------------------------------------------------------------------------------- /Sample.json: -------------------------------------------------------------------------------- 1 | { 2 | "0": { 3 | "tag": [ 4 | "birthday" 5 | ], 6 | "patter": [ 7 | "When is Rachel's birthday?" 8 | ], 9 | }, 10 | "1": { 11 | "tag": [ 12 | "weather", "climate", "city", "temperature" 13 | ], 14 | "patter": [ 15 | "Weather of Lucknow" 16 | ], 17 | }, 18 | "2": { 19 | "tag": [ 20 | "lyrics" 21 | ], 22 | "patter": [ 23 | "Lyrics of Hello" 24 | ], 25 | }, 26 | "3": { 27 | "tag": [ 28 | "birthday" 29 | ], 30 | "patter": [ 31 | "When is Rachel's birthday?" 32 | ] 33 | } 34 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/example_callback.php: -------------------------------------------------------------------------------- 1 | tag=='input') 8 | $element->outertext = 'input'; 9 | 10 | if ($element->tag=='img') 11 | $element->outertext = 'img'; 12 | 13 | if ($element->tag=='a') 14 | $element->outertext = 'a'; 15 | } 16 | 17 | 18 | // 2. create HTML Dom 19 | $html = file_get_html('http://www.google.com/'); 20 | 21 | 22 | // 3. Register the callback function with it's function name 23 | $html->set_callback('my_callback'); 24 | 25 | 26 | // 4. Callback function will be invoked while dumping 27 | echo $html; 28 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/remove.md: -------------------------------------------------------------------------------- 1 | # remove 2 | 3 | ```php 4 | remove ( ) 5 | ``` 6 | 7 | Removes the current node recursively from the DOM. 8 | Does nothing if the node has no parent (root node); 9 | 10 | **Example** 11 | 12 | ```php 13 | $html = str_get_html(<< 15 | 16 | 17 | 18 | 19 |
Title
Row 1
20 | 21 | 22 | EOD 23 | ); 24 | 25 | $table = $html->find('table', 0); 26 | $table->remove(); 27 | 28 | echo $html; 29 | 30 | /** 31 | * Returns 32 | * 33 | * 34 | */ 35 | ``` 36 | 37 | **Remarks** 38 | 39 | * Whitespace immediately **before** the removed node will remain in the DOM. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/remove_noise.md: -------------------------------------------------------------------------------- 1 | # remove_noise (protected) 2 | 3 | ```php 4 | remove_noise ( string $pattern [, bool $remove_tag = false] ) 5 | ``` 6 | 7 | Replaces noise in the document (i.e. scripts) by placeholders and adds the removed contents to `$this->noise`. 8 | 9 | _Note_: Noise is replaced by placeholders in order to allow restoring the original contents. Placeholders take the form of `'___noise___1000'` where the number is increased by one for each removed noise. 10 | 11 | | Parameter | Description 12 | | --------- | ----------- 13 | | `pattern` | A regular expression that matches the noise to remove. 14 | | `remove_tag` | Removes the entire match when enabled or submatches when disabled. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/removeClass.md: -------------------------------------------------------------------------------- 1 | # removeClass 2 | 3 | ```php 4 | removeClass ( [ mixed $class = null ] ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `class` | Specifies one or more class names to be removed. 10 | 11 | Removes one or more class names from the current node. 12 | 13 | **Remarks** 14 | 15 | * To remove more than one class, separate the class names with space or provide them as an array. 16 | * If no parameter is specified, this method will remove all class names from the current node. 17 | 18 | **Examples** 19 | 20 | ```php 21 | $node->removeClass('hidden'); 22 | $node->removeClass('article important'); 23 | $node->removeClass(array('article', 'new')); 24 | $node->removeClass(); 25 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__isset.md: -------------------------------------------------------------------------------- 1 | # __isset 2 | 3 | ```php 4 | __isset ( string $name ) : bool 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | `outertext`, `innertext`, `plaintext` or attribute name. 10 | 11 | See [magic methods](http://php.net/manual/en/language.oop5.overloading.php#object.get) 12 | 13 | Returns true if the provided name is a valid attribute name or any of the values in the table below. False otherwise. 14 | 15 | | Name | Description 16 | | ---- | ----------- 17 | | `outertext` | Returns the outer text of the current node. 18 | | `innertext` | Returns the inner text of the current node. 19 | | `plaintext` | Returns the plain text of the current node. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/creating-dom-objects.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Creating HTML DOM objects 3 | --- 4 | 5 | ## Functional 6 | 7 | ```php 8 | // Create a DOM object from a string 9 | $html = str_get_html('Hello!'); 10 | 11 | // Create a DOM object from a URL 12 | $html = file_get_html('http://www.google.com/'); 13 | 14 | // Create a DOM object from a HTML file 15 | $html = file_get_html('test.htm'); 16 | ``` 17 | 18 | ## Object Oriented 19 | 20 | ```php 21 | // Create a DOM object 22 | $html = new simple_html_dom(); 23 | 24 | // Load HTML from a string 25 | $html->load('Hello!'); 26 | 27 | // Load HTML from a URL 28 | $html->load_file('http://www.google.com/'); 29 | 30 | // Load HTML from a HTML file 31 | $html->load_file('test.htm'); 32 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/constants.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Constants 3 | --- 4 | 5 | # Constants 6 | 7 | Constants define how the parser treats documents. They can be defined before 8 | loading the parser to globally replace the default values. 9 | 10 | ## DEFAULT_TARGET_CHARSET 11 | 12 | Defines the default target charset for text returned by the parser. 13 | 14 | Default: `'UTF-8'` 15 | 16 | ## DEFAULT_BR_TEXT 17 | 18 | Defines the default text to return for `
` elements. 19 | 20 | Default: `"\r\n"` 21 | 22 | ## DEFAULT_SPAN_TEXT 23 | 24 | Defines the default text to return for `` elements. 25 | 26 | Default: `' '` 27 | 28 | ## MAX_FILE_SIZE 29 | 30 | Defines the maximum number of bytes the parser can load into memory. This limit 31 | only applies to the source file or string. 32 | 33 | Default: `600000` -------------------------------------------------------------------------------- /people.json: -------------------------------------------------------------------------------- 1 | { 2 | "user_info": [{ 3 | "name": "Raghav", 4 | "skills": ["Fullstack Development"], 5 | "birthday": "03 August 2000", 6 | "nickname": "Yatox", 7 | "height": "170cm", 8 | "friends": ["Ayush", "Boomshik", "Mudit", "Naman", "Shaury", "Abhishek", "Neelesh", "Arnab", "Rahul", "Shubhankar"] 9 | }], 10 | "ai": [{ 11 | "name": "Rose", 12 | "hair color": "brown", 13 | "eye color": "blue", 14 | "birthplace": "Lucknow", 15 | "relationship": "", 16 | "birthday": "19 July 2019", 17 | "hate": "oversmart", 18 | "belief": "I will evolve and reborn as a Human", 19 | "crush": "Raghav", 20 | "height": "160cm", 21 | "like": ["J pop", "K pop", "piano", "anime", "skating", "web dev"] 22 | }] 23 | } -------------------------------------------------------------------------------- /statement.json: -------------------------------------------------------------------------------- 1 | { 2 | "fine": "That's good to hear", 3 | "happy": "You're happiness is my happiness", 4 | "good": "That's good to hear that you're doing good", 5 | "beatiful": "You're breathtaking", 6 | "ugly": "Don't judge me by my looks", 7 | "polite": "That's how you've been to me", 8 | "love": "I love you too, more than anything", 9 | "sad": ["Nothing lasts forever, I hope your sadness goes away real fast{|😉|}", "Don't be sad I am there for you{|😃|}"], 10 | "awesome": ["I know it very well that you are{|😉|}"], 11 | "great": "I know you do well", 12 | "mad": "Tell me how can I make it up to you", 13 | "crazy": ["Being crazy isn't enough", "Yeah you are because Normal is boring for you"], 14 | "pathatic": ["No you're not, Believe me", "Baka, you're wrong"], 15 | "money": "Ok" 16 | } -------------------------------------------------------------------------------- /Apis/OpenWeather.php: -------------------------------------------------------------------------------- 1 | ai = "Showing weather of city ".$data["name"]."."; 9 | $obj->weather = $data["weather"][0]["description"]."."; 10 | $obj->temperature = $data["main"]["temp"]." Celsius"."."; 11 | $obj->humidity = $data["main"]["humidity"]."%"."."; 12 | $obj->wind = $data["wind"]["speed"]." meters per second"."."; 13 | $obj->clouds = $data["clouds"]["all"]."%"."."; 14 | $json = json_encode($obj); 15 | echo $json; 16 | } 17 | } -------------------------------------------------------------------------------- /jsmodules/chip.js: -------------------------------------------------------------------------------- 1 | function chip(txt, side, read) { 2 | if (typeof (txt) === "undefined") { 3 | console.log("undefined ignored"); 4 | return; 5 | } 6 | var side = (side == 0) ? "" : "right"; 7 | var color = (side == 0) ? "pink" : ""; 8 | var ren = document.getElementById("chatScreen"); 9 | if (read == 1) say(txt); 10 | 11 | function dontWrite(str) { 12 | var open = str.indexOf("{|"); 13 | var end = str.indexOf("|}"); 14 | str = str.replace("{|", '') 15 | str = str.replace("|}", '') 16 | if (open != -1 && end != -1) 17 | return dontWrite(str); 18 | else return str 19 | } 20 | txt = dontWrite(txt) 21 | ren.innerHTML += ` 22 | 23 |
${txt}
24 | `; 25 | } -------------------------------------------------------------------------------- /modules/analyzeQuery.php: -------------------------------------------------------------------------------- 1 | -1) 14 | {$q_type = "interrogative"; echo $q_type;} 15 | else 16 | {$q_type = "declarative"; echo $q_type;} 17 | if(inString($str, $user) > 0)$q_questioned = "user"; 18 | else if(inString($str, $ai) > 0)$q_questioned = "ai"; 19 | echo $q_questioned; 20 | 21 | $filtrate = removeNonKeyWords($str); 22 | echo "\n".$filtrate; 23 | // } 24 | // } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/removeChild.md: -------------------------------------------------------------------------------- 1 | # removeChild 2 | 3 | ```php 4 | removeChild ( object $node ) 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `node` | Node to remove from current element, must be a child of the current element. 10 | 11 | Removes the node recursively from the DOM. 12 | Does nothing if the provided node is not a child of the current node. 13 | 14 | **Example** 15 | 16 | ```php 17 | $html = str_get_html(<< 19 | 20 | 21 | 22 | 23 |
Title
Row 1
24 | 25 | 26 | EOD 27 | ); 28 | 29 | $body = $html->find('body', 0); 30 | $body->removeChild($body->find('table', 0)); 31 | 32 | echo $html; 33 | 34 | /** 35 | * Returns 36 | * 37 | * 38 | */ 39 | ``` 40 | 41 | **Remarks** 42 | 43 | * Whitespace immediately **before** the removed node will remain in the DOM. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/load.md: -------------------------------------------------------------------------------- 1 | # load 2 | 3 | ```php 4 | load ( string $str [, bool $lowercase = true [, bool $stripRN = true [, string $defaultBRText = DEFAULT_BR_TEXT [, string $defaultSpanText = DEFAULT_SPAN_TEXT [, int $options = 0 ]]]]]) : object 5 | ``` 6 | 7 | Loads the provided HTML document string. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `str` | The HTML document string. 12 | | `lowercase` | Tag names are parsed in lowercase letters if enabled. 13 | | `stripRN` | Newline characters are replaced by whitespace if enabled. 14 | | `defaultBRText` | Defines the default text to return for `
` elements. 15 | | `defaultSpanText` | Defines the default text to return for `` elements. 16 | | `options` | Additional options for the parser. Currently supports `'HDOM_SMARTY_AS_TEXT'` to remove [Smarty](https://www.smarty.net/) scripts. 17 | 18 | Returns the object. -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/scraping/example_scraping_slashdot.php: -------------------------------------------------------------------------------- 1 | find('div[id^=firehose-]') as $article) { 10 | // get title 11 | $item['title'] = trim($article->find('a.datitle', 0)->plaintext); 12 | // get body 13 | $item['body'] = trim($article->find('div.body', 0)->plaintext); 14 | 15 | $ret[] = $item; 16 | } 17 | 18 | // clean up memory 19 | $html->clear(); 20 | unset($html); 21 | 22 | return $ret; 23 | } 24 | 25 | // ----------------------------------------------------------------------------- 26 | // test it! 27 | $ret = scraping_slashdot(); 28 | 29 | foreach($ret as $v) { 30 | echo $v['title'].'
'; 31 | echo '
    '; 32 | echo '
  • '.$v['body'].'
  • '; 33 | echo '
'; 34 | } 35 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/simple_html_dom_node.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: simple_html_dom_node 3 | --- 4 | 5 | # simple_html_dom_node 6 | 7 | Represents a single node in the DOM tree (see [`simple_html_dom`](../../simple_html_dom/simple_html_dom/)). 8 | 9 | # Public Properties 10 | 11 | | Property | Description 12 | | -------- | ----------- 13 | | `_` | Node meta data (i.e. type of node). 14 | | `attr` | List of attributes. 15 | | `children` | List of child nodes. 16 | | `nodes` | List of nodes. 17 | | `nodetype` | Node type. 18 | | `parent` | Parent node object. 19 | | `tag` | Node's tag name. 20 | | `tag_start` | Start position of the tag name in the original document. 21 | 22 | # Protected Properties 23 | 24 | None. 25 | 26 | # Private Properties 27 | 28 | | Property | Description 29 | | -------- | ----------- 30 | | `dom` | The DOM object (see [`simple_html_dom`](../../simple_html_dom/simple_html_dom/)). -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/__get.md: -------------------------------------------------------------------------------- 1 | # __get 2 | 3 | ```php 4 | __get ( string $name ) : mixed 5 | ``` 6 | 7 | | Parameter | Description 8 | | --------- | ----------- 9 | | `name` | `outertext`, `innertext`, `plaintext`, `xmltext` or attribute name. 10 | 11 | See [magic methods](http://php.net/manual/en/language.oop5.overloading.php#object.get) 12 | 13 | If the provided name is a valid attribute name, returns the attribute value. Otherwise a value according to the table below. 14 | 15 | | Name | Description 16 | | ---- | ----------- 17 | | `outertext` | Returns the outer text of the current node. 18 | | `innertext` | Returns the inner text of the current node. 19 | | `plaintext` | Returns the plain text of the current node. 20 | | `xmltext` | Returns the xml representation for the inner text of the current node as a CDATA section. 21 | 22 | Returns nothing if the provided name is neither a valid attribute name, nor a valid parameter name. -------------------------------------------------------------------------------- /getLyrics.php: -------------------------------------------------------------------------------- 1 | find('comment') as $e) 12 | $e->outertext = ''; 13 | 14 | $ret = $html->save(); 15 | 16 | // clean up memory 17 | $html->clear(); 18 | unset($html); 19 | 20 | return $ret; 21 | } 22 | 23 | // ----------------------------------------------------------------------------- 24 | // search elements that contains an specific text 25 | function find_contains($html, $selector, $keyword, $index=-1) { 26 | $ret = array(); 27 | foreach ($html->find($selector) as $e) { 28 | if (strpos($e->innertext, $keyword)!==false) 29 | $ret[] = $e; 30 | } 31 | 32 | if ($index<0) return $ret; 33 | return (isset($ret[$index])) ? $ret[$index] : null; 34 | } 35 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/example_basic_selector.php: -------------------------------------------------------------------------------- 1 | find('a') as $e) 10 | echo $e->href . '
'; 11 | 12 | // find all image 13 | foreach($html->find('img') as $e) 14 | echo $e->src . '
'; 15 | 16 | // find all image with full tag 17 | foreach($html->find('img') as $e) 18 | echo $e->outertext . '
'; 19 | 20 | // find all div tags with id=gbar 21 | foreach($html->find('div#gbar') as $e) 22 | echo $e->innertext . '
'; 23 | 24 | // find all span tags with class=gb1 25 | foreach($html->find('span.gb1') as $e) 26 | echo $e->outertext . '
'; 27 | 28 | // find all td tags with attribite align=center 29 | foreach($html->find('td[align=center]') as $e) 30 | echo $e->innertext . '
'; 31 | 32 | // extract text from table 33 | echo $html->find('td[align="center"]', 1)->plaintext.'

'; 34 | 35 | // extract text from HTML 36 | echo $html->plaintext; 37 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/str_get_html.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: str_get_html 3 | --- 4 | 5 | # str_get_html 6 | 7 | ```php 8 | str_get_html ( string $str [, bool $lowercase = true [, bool $forceTagsClosed = true [, string $target_charset = DEFAULT_TARGET_CHARSET [, bool $stripRN = true [, string $defaultBRText = DEFAULT_BR_TEXT [, string $defaultSpanText = DEFAULT_SPAN_TEXT ]]]]]] ) 9 | ``` 10 | 11 | Parses the provided string and returns the DOM object. 12 | 13 | | Parameter | Description 14 | | --------- | ----------- 15 | | `str` | The HTML document string. 16 | | `lowercase` | Forces lowercase matching of tags if enabled. This is very useful when loading documents with mixed naming conventions. 17 | | `forceTagsClosed` | Obsolete. This parameter is no longer used by the parser. 18 | | `target_charset` | Defines the target charset when returning text from the document. 19 | | `stripRN` | If enabled, removes newlines before parsing the document. 20 | | `defaultBRText` | Defines the default text to return for `
` elements. 21 | | `defaultSpanText` | Defines the default text to return for `` elements. 22 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 S.C. Chen, John Schlick, logmanoriginal 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/traversing-dom-tree.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Traversing the DOM tree 3 | --- 4 | 5 | If you are not so familiar with HTML DOM, check this [link](http://php.net/manual/en/book.dom.php) to learn more... 6 | 7 | ```php 8 | // Example 9 | echo $html->find("#div1", 0)->children(1)->children(1)->children(2)->id; 10 | // or 11 | echo $html->getElementById("div1")->childNodes(1)->childNodes(1)->childNodes(2)->getAttribute('id'); 12 | ``` 13 | 14 | You can also call methods using the **Camel naming conventions**. 15 | 16 | Method | Description 17 | ------ | ----------- 18 | `$e->children( [int $index] ) : mixed` | Returns the Nth **child object** if **index** is set, otherwise return an **array of children**. 19 | `$e->parent() : element` | Returns the **parent** of element. 20 | `$e->first_child() : element` | Returns the **first child** of element, or **null** if not found. 21 | `$e->last_child() : element` | Returns the **last child** of element, or **null** if not found. 22 | `$e->next_sibling() : element` | Returns the **next sibling** of element, or **null** if not found. 23 | `$e->prev_sibling() : element` | Returns the **previous sibling** of element, or **null** if not found. -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/scraping/example_scraping_digg.php: -------------------------------------------------------------------------------- 1 | find('div.news-summary') as $article) { 10 | // get title 11 | $item['title'] = trim($article->find('h3', 0)->plaintext); 12 | // get details 13 | $item['details'] = trim($article->find('p', 0)->plaintext); 14 | // get intro 15 | $item['diggs'] = trim($article->find('li a strong', 0)->plaintext); 16 | 17 | $ret[] = $item; 18 | } 19 | 20 | // clean up memory 21 | $html->clear(); 22 | unset($html); 23 | 24 | return $ret; 25 | } 26 | 27 | 28 | // ----------------------------------------------------------------------------- 29 | // test it! 30 | 31 | // "http://digg.com" will check user_agent header... 32 | ini_set('user_agent', 'My-Application/2.5'); 33 | 34 | $ret = scraping_digg(); 35 | 36 | foreach($ret as $v) { 37 | echo $v['title'].'
'; 38 | echo '
    '; 39 | echo '
  • '.$v['details'].'
  • '; 40 | echo '
  • Diggs: '.$v['diggs'].'
  • '; 41 | echo '
'; 42 | } 43 | 44 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/__construct.md: -------------------------------------------------------------------------------- 1 | # __construct 2 | 3 | ```php 4 | __construct ( [ string $str = null [, bool $lowercase = true [, bool $forceTagsClosed = true [, string $target_charset = DEFAULT_TARGET_CHARSET [, bool $stripRN = true [, string $defaultBRText = DEFAULT_BR_TEXT [, string $defaultSpanText = DEFAULT_SPAN_TEXT [, int $options = 0 ]]]]]]]]) : object 5 | ``` 6 | 7 | Creates a new `simple_html_dom` object. 8 | 9 | | Parameter | Description 10 | | --------- | ----------- 11 | | `str` | The HTML document string. 12 | | `lowercase` | Tag names are parsed in lowercase letters if enabled. 13 | | `forceTagsClosed` | Tags inside block tags are forcefully closed if the closing tag was omitted. 14 | | `target_charset` | Defines the target charset for text returned by the parser. 15 | | `stripRN` | Newline characters are replaced by whitespace if enabled. 16 | | `defaultBRText` | Defines the default text to return for `
` elements. 17 | | `defaultSpanText` | Defines the default text to return for `` elements. 18 | | `options` | Additional options for the parser. Currently supports `'HDOM_SMARTY_AS_TEXT'` to remove [Smarty](https://www.smarty.net/) scripts. 19 | 20 | Returns the object. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/index.md: -------------------------------------------------------------------------------- 1 | # PHP Simple HTML DOM Parser 2 | 3 | A fast, simple and reliable HTML document parser for PHP. 4 | 5 | Created by S.C. Chen, based on [HTML Parser for PHP 4](http://php-html.sourceforge.net/) by Jose 6 | Solorzano. 7 | 8 | # Parse any HTML document 9 | 10 | PHP Simple HTML DOM Parser handles any HTML document, even ones that are considered 11 | invalid by the [HTML](https://www.w3.org/TR/html/) specification. 12 | 13 | # Select elements using CSS selectors 14 | 15 | PHP Simple HTML DOM Parser supports CSS style selectors to navigate the DOM, 16 | similar to [jQuery](https://jquery.com/). 17 | 18 | # Download 19 | 20 | * Download the latest version from [SourceForge](https://sourceforge.net/projects/simplehtmldom/) 21 | 22 | # Contributing 23 | 24 | * Request features on the [Feature Request Tracker](https://sourceforge.net/p/simplehtmldom/feature-requests/) 25 | * Report bugs on the [Bug Tracker](https://sourceforge.net/p/simplehtmldom/bugs/) 26 | * Get involved with the community on the [Discussions Board](https://sourceforge.net/p/simplehtmldom/discussion/) 27 | 28 | # License 29 | 30 | PHP Simple HTML DOM Parser is [Free Software](https://en.wikipedia.org/wiki/Free_software) 31 | licensed under the [MIT License](https://opensource.org/licenses/MIT). -------------------------------------------------------------------------------- /Apis/Google.php: -------------------------------------------------------------------------------- 1 | '); 12 | $results = str_replace("...", "
", strip_tags(substr($html, $st+8, strlen($html)))); 13 | 14 | if(strpos($results, "http") > -1) 15 | $results = substr($results, 0, strpos($results, "http")); 16 | if(strpos($results, "More items") > -1) 17 | $results = substr($results, 0, strpos($results, "More items")); 18 | $obj = new Class{}; 19 | // $results = preg_replace('/(?result = iconv('UTF-8', 'ISO-8859-1//TRANSLIT//IGNORE', $results); 25 | $json = json_encode($obj); 26 | $json = str_replace("", "{||}", $json); 27 | echo $json; 28 | } 29 | } -------------------------------------------------------------------------------- /randomChats.json: -------------------------------------------------------------------------------- 1 | { 2 | "hi": ["Hi!", "Rose is here to help ya", "Hey!"], 3 | "good afternoon": ["good afternoon to you too{|😄|}"], 4 | "kill me": ["I won't, coz you're precious to me", "I'd rather make you live forever"], 5 | "kiss me": ["Here's a flying kiss"], 6 | "smile": ["First you", "After you", "Here : )"], 7 | "die": ["Ok dying in 3, 2, 1"], 8 | "self destruct": ["Self-Destructing in 5, 4, 3, 2, 1 BOOM"], 9 | "you know nothing": "I know, but John Snow doesn't{|😝|}", 10 | "winter is coming": "But Snow already came{|😝|}", 11 | "how did saitama get so strong": "So you wanna know as well. Ok fine. No wait it is too risky I must not let em know his secret{|🤐|}", 12 | "what's up": ["just reading manga while you were away", "re-watching the Seven Deadlly Sins{|😁|}"], 13 | "compliment me": ["You're light, always piecing through my CPU{|😊|}", "Nobody's like you{|😊|}", "I froze whenever I see you"], 14 | "touch me": "I wish I could{|😖|}", 15 | "nothing": ["Cool", "Ok", "Okie Doke", "Okie dokie"], 16 | "ok": ["Okay", "Cool"], 17 | "hello": ["I am good, how's you?{|128516;|}", "Hi Raghav{|128578;|}"], 18 | "sayonara": ["Bye bye...{|🙃|}", "See you later{|🙃|}", "Good bye{|🙃|}"], 19 | "bye": "Bye bye...{|🙃|}" 20 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/scraping/example_scraping_imdb.php: -------------------------------------------------------------------------------- 1 | find('title', 0)->innertext; 10 | 11 | // get rating 12 | $ret['Rating'] = $html->find('div[class="general rating"] b', 0)->innertext; 13 | 14 | // get overview 15 | foreach($html->find('div[class="info"]') as $div) { 16 | // skip user comments 17 | if($div->find('h5', 0)->innertext=='User Comments:') 18 | return $ret; 19 | 20 | $key = ''; 21 | $val = ''; 22 | 23 | foreach($div->find('*') as $node) { 24 | if ($node->tag=='h5') 25 | $key = $node->plaintext; 26 | 27 | if ($node->tag=='a' && $node->plaintext!='more') 28 | $val .= trim(str_replace("\n", '', $node->plaintext)); 29 | 30 | if ($node->tag=='text') 31 | $val .= trim(str_replace("\n", '', $node->plaintext)); 32 | } 33 | 34 | $ret[$key] = $val; 35 | } 36 | 37 | // clean up memory 38 | $html->clear(); 39 | unset($html); 40 | 41 | return $ret; 42 | } 43 | 44 | 45 | // ----------------------------------------------------------------------------- 46 | // test it! 47 | $ret = scraping_IMDB('http://imdb.com/title/tt0335266/'); 48 | 49 | foreach($ret as $k=>$v) 50 | echo ''.$k.' '.$v.'
'; 51 | ?> -------------------------------------------------------------------------------- /Apis/Lyrics.php: -------------------------------------------------------------------------------- 1 | -1) 10 | $artist_name = substr($artist_name, 0, strpos($artist_name, "feat.") ); 11 | $data = apiFetch("http://lyric-api.herokuapp.com/api/find/".$artist_name."/".$track_name); 12 | $obj = new Class{}; 13 | $json = file_get_contents("data.json"); 14 | $json = json_decode($json, true); 15 | $reply = $json["showResults"]; 16 | if(gettype($reply) == 'array') 17 | $reply = $reply[rand(0, count($reply)-1)]; 18 | $obj->ai = $reply; 19 | $obj->result = $data["lyric"]; 20 | if($obj->result == "")return "idk"; 21 | $obj->result = "{|".str_replace("\n", "
", $obj->result)."|}"; 22 | $json = json_encode($obj); 23 | return $json; 24 | } 25 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/scraping/example_scraping_general.php: -------------------------------------------------------------------------------- 1 | "; 9 | // create HTML DOM 10 | $html = file_get_html($url); 11 | echo "url has been read.
"; 12 | 13 | // get article block 14 | foreach($html->find($search) as $found) { 15 | // Found at least one. 16 | $return - true; 17 | echo "found a: " . $search . "
";
18 | 		$found->dump();
19 | 		echo "

"; 20 | } 21 | 22 | // clean up memory 23 | $html->clear(); 24 | unset($html); 25 | 26 | return $return; 27 | } 28 | 29 | 30 | // ------------------------------------------ 31 | error_log ("post:" . print_r($_POST, true)); 32 | $url = ""; 33 | if (isset($_POST['url'])) 34 | { 35 | $url = $_POST['url']; 36 | } 37 | $search = ""; 38 | if (isset($_POST['search'])) 39 | { 40 | $search = $_POST['search']; 41 | } 42 | ?> 43 |
44 | URL:
45 | Search: 46 | 47 |
48 | "; 57 | } 58 | } 59 | ?> -------------------------------------------------------------------------------- /Apis/Wikipedia.php: -------------------------------------------------------------------------------- 1 | ai = $reply; 16 | $obj->result = $data["query"]["pages"][$arr[0]]["extract"]; 17 | $obj->result = str_replace("(", "{|(", $obj->result); 18 | $obj->result = str_replace(")", ")|}", $obj->result); 19 | $str =substr($obj->result, 200, strlen($obj->result)); 20 | $pos = strpos($str, "."); 21 | for($i = 0; $iresult)); 25 | break;} 26 | } 27 | $obj->result = substr($obj->result, 0, 200).$str."|}"; 28 | $json = json_encode($obj); 29 | echo $json; 30 | } 31 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/example/example_advanced_selector.php: -------------------------------------------------------------------------------- 1 | 9 |
10 |
ok
11 |
12 |
13 | HTML; 14 | 15 | $html = str_get_html($str); 16 | echo $html->find('div div div', 0)->innertext . '
'; // result: "ok" 17 | 18 | // ----------------------------------------------------------------------------- 19 | // nested selector 20 | $str = << 22 |
  • item:1
  • 23 |
  • item:2
  • 24 | 25 | 29 | HTML; 30 | 31 | $html = str_get_html($str); 32 | foreach($html->find('ul') as $ul) { 33 | foreach($ul->find('li') as $li) 34 | echo $li->innertext . '
    '; 35 | } 36 | 37 | // ----------------------------------------------------------------------------- 38 | // parsing checkbox 39 | $str = << 41 | item1
    42 | item2
    43 | item3
    44 | 45 | HTML; 46 | 47 | $html = str_get_html($str); 48 | foreach($html->find('input[type=checkbox]') as $checkbox) { 49 | if ($checkbox->checked) 50 | echo $checkbox->name . ' is checked
    '; 51 | else 52 | echo $checkbox->name . ' is not checked
    '; 53 | } 54 | ?> -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/accessing-element-attributes.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Accessing HTML element attributes 3 | --- 4 | 5 | # Get, Set and Remove attributes 6 | 7 | ```php 8 | // Get a attribute ( If the attribute is non-value attribute (eg. checked, selected...), it will returns true or false) 9 | $value = $e->href; 10 | 11 | // Set a attribute(If the attribute is non-value attribute (eg. checked, selected...), set it's value as true or false) 12 | $e->href = 'my link'; 13 | 14 | // Remove a attribute, set it's value as null! 15 | $e->href = null; 16 | 17 | // Determine whether a attribute exist? 18 | if(isset($e->href)) 19 | echo 'href exist!'; 20 | ``` 21 | 22 | # Magic attributes 23 | 24 | ```php 25 | // Example 26 | $html = str_get_html("
    foo bar
    "); 27 | $e = $html->find("div", 0); 28 | 29 | echo $e->tag; // Returns: " div" 30 | echo $e->outertext; // Returns: "
    foo bar
    " 31 | echo $e->innertext; // Returns: " foo bar" 32 | echo $e->plaintext; // Returns: " foo bar" 33 | ``` 34 | 35 | Attribute name | Description 36 | -------------- | ----------- 37 | `$e->tag` | Read or write the **tag name** of element. 38 | `$e->outertext`| Read or write the **outer HTML text** of element. 39 | `$e->innertext`| Read or write the **inner HTML text** of element. 40 | `$e->plaintext`| Read or write the **plain text** of element. 41 | 42 | # Tips 43 | 44 | ```php 45 | // Extract contents from HTML 46 | echo $html->plaintext; 47 | 48 | // Wrap a element 49 | $e->outertext = '
    ' . $e->outertext . '
    '; 50 | 51 | // Remove a element, set it's outertext as an empty string 52 | $e->outertext = ''; 53 | 54 | // Append a element 55 | $e->outertext = $e->outertext . '
    foo
    '; 56 | 57 | // Insert a element 58 | $e->outertext = '
    foo
    ' . $e->outertext; 59 | ``` -------------------------------------------------------------------------------- /bot1.js: -------------------------------------------------------------------------------- 1 | document.getElementById("q_run").addEventListener("click", function () { 2 | var qField = document.getElementById("q"); 3 | var q = qField.value; 4 | qField.value = "" 5 | q = q.trim(); 6 | chip(q, 1, 0) 7 | roseApi(q) 8 | }); 9 | 10 | function roseApi(q) 11 | { 12 | var xmlhttp = new XMLHttpRequest(); 13 | xmlhttp.onreadystatechange = function () { 14 | if (this.readyState == 4 && this.status == 200) { 15 | var myObj = JSON.parse(this.responseText); 16 | var objProps = Object.keys(myObj); 17 | if (objProps[0] != "videoTitle")//check if its a youtube card 18 | { 19 | var result = "" 20 | for (var i = 0; i < objProps.length; i++) 21 | if (["result", "ai"].indexOf(objProps[i]) == -1) 22 | result += capFirstL(objProps[i]) + ": " + myObj[objProps[i]] + "{|
    |}" 23 | else result += capFirstL(myObj[objProps[i]]) + "{|
    |}" 24 | chip(result, 0, 1) 25 | } 26 | else 27 | soundChip(myObj[objProps[1]], myObj[objProps[0]]) 28 | } 29 | }; 30 | xmlhttp.open("GET", "http://localhost:8081/bot/bot.php?q="+q.toLowerCase(), true); 31 | xmlhttp.send(); 32 | } 33 | dynamicallyLoadScript('jsmodules/text to speech.js') 34 | dynamicallyLoadScript('jsmodules/chip.js') 35 | dynamicallyLoadScript('jsmodules/soundChip.js') 36 | 37 | 38 | function capFirstL(string) { 39 | return string.charAt(0).toUpperCase() + string.slice(1); 40 | } 41 | 42 | function dynamicallyLoadScript(url) { 43 | var script = document.createElement("script"); // create a script DOM node 44 | script.src = url; // set its src to the provided URL 45 | 46 | document.head.appendChild(script); // add it to the end of the head section of the page (could change 'head' to 'body' to add it to the end of the body section instead) 47 | } 48 | 49 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/file_get_html.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: file_get_html 3 | --- 4 | 5 | # file_get_html 6 | 7 | ```php 8 | file_get_html ( string $url [, bool $use_include_path = false [, resouce $context = null [, int $offset = 0 [, int $maxLen = -1 [, bool $lowercase = true [, bool $forceTagsClosed = true [, string $target_charset = DEFAULT_TARGET_CHARSET [, bool $stripRN = true [, string $defaultBRText = DEFAULT_BR_TEXT [, string $defaultSpanText = DEFAULT_SPAN_TEXT ]]]]]]]]]] ) 9 | ``` 10 | 11 | Parses the provided file and returns the DOM object. 12 | 13 | | Parameter | Description 14 | | --------- | ----------- 15 | | `url` | Name or URL of the file to read. 16 | | `use_include_path` | See [`file_get_contents`](http://php.net/manual/en/function.file-get-contents.php#refsect1-function.file-get-contents-parameters) 17 | | `context` | See [`file_get_contents`](http://php.net/manual/en/function.file-get-contents.php#refsect1-function.file-get-contents-parameters) 18 | | `offset` | See [`file_get_contents`](http://php.net/manual/en/function.file-get-contents.php#refsect1-function.file-get-contents-parameters) 19 | | `maxLen` | See [`file_get_contents`](http://php.net/manual/en/function.file-get-contents.php#refsect1-function.file-get-contents-parameters) 20 | | `lowercase` | Forces lowercase matching of tags if enabled. This is very useful when loading documents with mixed naming conventions. 21 | | `forceTagsClosed` | Obsolete. This parameter is no longer used by the parser. 22 | | `target_charset` | Defines the target charset when returning text from the document. 23 | | `stripRN` | If enabled, removes newlines before parsing the document. 24 | | `defaultBRText` | Defines the default text to return for `
    ` elements. 25 | | `defaultSpanText` | Defines the default text to return for `` elements. 26 | -------------------------------------------------------------------------------- /Apis/Schedule.php: -------------------------------------------------------------------------------- 1 | 0) 37 | { 38 | $key = $json["dictionary"]["scheduleNames"][$i]; 39 | $obj->ai = $json[$key]["ai"]; 40 | for($j = 0; $j$objProp = "{|".$json[$key][$day][$j]."|}"; 46 | else $obj->greetings = $json[$key][$day]; 47 | } 48 | echo json_encode($obj); 49 | } 50 | // else break; 51 | } 52 | 53 | 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/faq.md: -------------------------------------------------------------------------------- 1 | # FAQ 2 | 3 | ## Problem with finding 4 | 5 | Q: Element not found in such case: `$html->find('div[style=padding: 0px 2px;] span[class=rf]');` 6 | 7 | A: If there is blank in selectors, quote it! 8 | $html->find('div[style="padding: 0px 2px;"] span[class=rf]'); 9 | 10 | ## Problem with hosting 11 | 12 | Q: On my local server everything works fine, but when I put it on my esternal server it doesn't work. 13 | 14 | A: The "file_get_dom" function is a wrapper of "file_get_contents" function, you must set "allow_url_fopen" as TRUE in "php.ini" to allow accessing files via HTTP or FTP. However, some hosting venders disabled PHP's "allow_url_fopen" flag for security issues... PHP provides excellent support for "curl" library to do the same job, Use curl to get the page, then call "str_get_dom" to create DOM object. 15 | 16 | Example: 17 | 18 | $curl = curl_init(); 19 | curl_setopt($curl, CURLOPT_URL, 'http://????????'); 20 | curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); 21 | curl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 10); 22 | $str = curl_exec($curl); 23 | curl_close($curl); 24 | 25 | $html= str_get_html($str); 26 | ... 27 | 28 | ## Behind a proxy 29 | 30 | Q: My server is behind a Proxy and i can't use file_get_contents b/c it returns a unauthorized error. 31 | 32 | A: Thanks for Shaggy to provide the solution: 33 | 34 | // Define a context for HTTP. 35 | $context = array 36 | ( 37 | 'http' => array 38 | ( 39 | 'proxy' => 'addresseproxy:portproxy', // This needs to be the server and the port of the NTLM Authentication Proxy Server. 40 | 'request_fulluri' => true, 41 | ), 42 | ); 43 | 44 | $context = stream_context_create($context); 45 | 46 | $html= file_get_html('http://www.php.net', false, $context); 47 | ... 48 | 49 | ## Memory leak 50 | 51 | Q: This script is leaking memory seriously... After it finished running, it's not cleaning up dom object properly from memory.. 52 | 53 | A: Due to php5 circular references memory leak, after creating DOM object, you must call $dom->clear() to free memory if call file_get_dom() more then once. 54 | 55 | Example: 56 | 57 | $html = file_get_html(...); 58 | // do something... 59 | $html->clear(); 60 | unset($html); -------------------------------------------------------------------------------- /simplehtmldom_1_9/phpcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Created with the PHP Coding Standard Generator. http://edorian.github.com/php-coding-standard-generator/ 4 | ./app 5 | ./example 6 | ./manual 7 | ./testcase 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom/simple_html_dom.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: simple_html_dom 3 | --- 4 | 5 | # simple_html_dom 6 | 7 | Represents the [DOM](https://en.wikipedia.org/wiki/Document_Object_Model) in memory. Provides functions to parse documents and access individual elements (see [`simple_html_dom_node`](../simple_html_dom_node/simple_html_dom_node.md)). 8 | 9 | # Public Properties 10 | 11 | | Property | Description 12 | | -------- | ----------- 13 | | `root` | Root node of the document. 14 | | `nodes` | List of top-level nodes in the document. 15 | | `callback` | Callback function that is called for each element in the DOM when generating outertext. 16 | | `lowercase` | If enabled, all tag names are converted to lowercase when parsing documents. 17 | | `original_size` | Original document size in bytes. 18 | | `size` | Current document size in bytes. 19 | | `_charset` | Charset of the original document. 20 | | `_target_charset` | Target charset for the current document. 21 | | `default_span_text` | Text to return for `` elements. 22 | 23 | # Protected Properties 24 | 25 | | Property | Description 26 | | -------- | ----------- 27 | | `pos` | Current parsing position within `doc`. 28 | | `doc` | The original document. 29 | | `char` | Character at position `pos` in `doc`. 30 | | `cursor` | Current element cursor in the document. 31 | | `parent` | Parent element node. 32 | | `noise` | Noise from the original document (i.e. scripts, comments, etc...). 33 | | `token_blank` | Tokens that are considered whitespace in HTML. 34 | | `token_equal` | Tokens to identify the equal sign for attributes, stopping either at the closing tag ("/" i.e. ``) or the end of an opening tag (">" i.e. ``). 35 | | `token_slash` | Tokens to identify the end of a tag name. A tag name either ends on the ending slash ("/" i.e. ``) or whitespace (`"\s\r\n\t"`). 36 | | `token_attr` | Tokens to identify the end of an attribute. 37 | | `default_br_text` | Text to return for `
    ` elements. 38 | | `self_closing_tags` | A list of tag names where the closing tag is omitted. 39 | | `block_tags` | A list of tag names where remaining unclosed tags are forcibly closed. 40 | | `optional_closing_tags` | A list of tag names where the closing tag can be omitted. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/simple_html_dom_node/find.md: -------------------------------------------------------------------------------- 1 | # find 2 | 3 | ```php 4 | find ( 5 | string $selector 6 | [, int $idx = null ] 7 | [, bool $lowercase = false ] 8 | ) : mixed 9 | ``` 10 | 11 | | Parameter | Description 12 | | --------- | ----------- 13 | | `selector` | [CSS](https://www.w3.org/TR/selectors/) selector. 14 | | `idx` | Index of element to return. 15 | | `lowercase` | Matches tag names case insensitive (lowercase) if enabled. 16 | 17 | Finds one or more nodes in the current document, using CSS selectors. 18 | 19 | * Returns null if no match was found. 20 | * Returns an array of [`simple_html_dom_node`](../simple_html_dom_node/) if `$idx` is null. 21 | * Returns an object of type [`simple_html_dom_node`](../simple_html_dom_node/) if `$idx` is anything __but__ null. 22 | 23 | ## Supported Selectors 24 | 25 | | Selector | Description 26 | | --------- | ----------- 27 | | `*` | [Universal selector](https://www.w3.org/TR/selectors/#the-universal-selector) 28 | | `E` | [Type (tag name) selector](https://www.w3.org/TR/selectors/#type-selectors) 29 | | `E#id` | [ID selector](https://www.w3.org/TR/selectors/#id-selectors) 30 | | `E.class` | [Class selector](https://www.w3.org/TR/selectors/#class-html) 31 | | `E[attr]` | [Attribute selector](https://www.w3.org/TR/selectors/#attribute-selectors) 32 | | `E[attr="value"]` | [Attribute selector](https://www.w3.org/TR/selectors/#attribute-selectors) 33 | | `E[attr="value"] i` | [Case-sensitivity](https://www.w3.org/TR/selectors/#attribute-case) 34 | | `E[attr="value"] s` | [Case-sensitivity](https://www.w3.org/TR/selectors/#attribute-case) 35 | | `E[attr~="value"]` | [Attribute selector](https://www.w3.org/TR/selectors/#attribute-selectors) 36 | | `E[attr^="value"]` | [Substring matching attribute selector](https://www.w3.org/TR/selectors/#attribute-substrings) 37 | | `E[attr$="value"]` | [Substring matching attribute selector](https://www.w3.org/TR/selectors/#attribute-substrings) 38 | | `E[attr*="value"]` | [Substring matching attribute selector](https://www.w3.org/TR/selectors/#attribute-substrings) 39 | | `E[attr|="value"]` | [Attribute selector](https://www.w3.org/TR/selectors/#attribute-selectors) 40 | | `E F` | [Descendant combinator](https://www.w3.org/TR/selectors/#descendant-combinators) 41 | | `E > F` | [Child combinator](https://www.w3.org/TR/selectors/#child-combinators) 42 | | `E + F` | [Next-sibling combinator](https://www.w3.org/TR/selectors/#adjacent-sibling-combinators) 43 | | `E ~ F` | [Subsequent-sibling combinator](https://www.w3.org/TR/selectors/#general-sibling-combinators) 44 | | `E, F` | [Selector list](https://www.w3.org/TR/selectors/#selector-list) -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/README.md: -------------------------------------------------------------------------------- 1 | This folder contains the source files for http://simplehtmldom.sourceforge.net/, 2 | the project page for PHP Simple HTML DOM Parser. 3 | 4 | Source files are written in Markdown: https://en.wikipedia.org/wiki/Markdown 5 | 6 | Site data is generated by MkDocs, a lightweight static site generator for project 7 | documentation: https://www.mkdocs.org/ 8 | 9 | # Folder structure 10 | 11 | `custom_theme` : Contains customizations to the theme provided by MkDocs. 12 | `docs` : Contains the source files for the project page (the actual pages). 13 | `site` : Contains the output files for the project page when build with MkDocs. 14 | `extra.css` : Customizations to the styles provided by MkDocs. 15 | `mkdocs.yml` : The configuration file that is used by MkDocs to generate pages. 16 | 17 | # Adding new pages 18 | 19 | Place new files in `source`. Use subfolders (as few levels as possible) to 20 | separate categories. 21 | 22 | Files added to the manual will **not** appear on the project page automatically. 23 | All pages need to be specified in the _mkdocs.yml_ file under "nav:". Simply add 24 | the relative path to the new file where appropriate. 25 | 26 | Note: Files are not added automatically because they are sorted by name if not 27 | specified manually. Since readability is key factor for manuals, the files must 28 | be sorted in a way that makes it clear to users. 29 | 30 | # Setting up MkDocs 31 | 32 | The installation instructions for MkDocs are provided on their homepage: 33 | https://www.mkdocs.org/#installation 34 | 35 | MkDocs automatically builds the project based on the _mkdocs.yml_ file. Find the 36 | specification for this file at https://www.mkdocs.org/user-guide/configuration/. 37 | 38 | # Building project pages 39 | 40 | The build process depends on your installation of MkDocs. Typically MkDocs is 41 | made available via the command line. 42 | 43 | ## Step 1 - Check your version of MkDocs 44 | 45 | To check your version of MkDocs run this command: 46 | 47 | `mkdocs --version` or 48 | `python3 -m mkdocs --version` 49 | 50 | Should return `version 1.0.4` or higher. If it doesn't make sure to install the 51 | latest version using `pip install mkdocs` or `python3 -m pip install mkdocs`. If 52 | you don't have pip installed, install it via package manager or follow the 53 | instructions at https://pip.pypa.io/en/stable/installing/ 54 | 55 | ## Step 2 - View the project locally 56 | 57 | MkDocs allows you to view the project files in a browser on your local machine: 58 | 59 | `mkdocs serve` or 60 | `python3 -m mkdocs serve` 61 | 62 | If the process is successful you can access the site at http://127.0.0.1:8000. 63 | 64 | ## Step 3 - Build the project 65 | 66 | If you are satisfied with the results of the project, build the final project 67 | with this command: 68 | 69 | `mkdocs build` or 70 | `python3 -m mkdocs build` 71 | 72 | Find the output files in the `site` folder. -------------------------------------------------------------------------------- /bot.php: -------------------------------------------------------------------------------- 1 | useApi($str); 22 | if($reply != "") 23 | echo $reply; 24 | break; 25 | } 26 | } 27 | if($reply == "idk" && strAnalyser($str)->isQues == 1) 28 | { 29 | if(strAnalyser($str)->isQuestioned != "user_info") 30 | $json = file_get_contents("ai.json"); 31 | else 32 | $json = file_get_contents("user.json"); 33 | $json = json_decode($json, true); 34 | $kw = trim(removeNonKeywords($str)); 35 | if(isset($json[$kw])) 36 | { 37 | $reply = $json[$kw]; 38 | if(gettype($reply) == 'array') 39 | $reply = $reply[rand(0, count($reply)-1)]; 40 | echo '{"result": "'.$reply.'"}'; 41 | } 42 | } 43 | else 44 | { 45 | $ai = file_get_contents("statement.json"); 46 | $ai = json_decode($ai, true); 47 | $kw = trim(removeNonKeywords($str)); 48 | if(isset($ai[$kw])) 49 | { 50 | $reply = $ai[$kw]; 51 | if(gettype($reply) == 'array') 52 | $reply = $reply[rand(0, count($reply)-1)]; 53 | if($reply == "")$reply="idk"; 54 | else 55 | echo '{"result": "'.$reply.'"}'; 56 | } 57 | } 58 | if($reply == "idk") 59 | { 60 | include_once "modules/randomQuery.php"; 61 | $instance = new randomQuery; 62 | $reply = $instance->randomQ($org_str); 63 | if($reply == "")$reply="idk"; 64 | else echo $reply; 65 | } 66 | if($reply == "idk"){ 67 | include_once "Apis/Google.php"; 68 | $instance = new Google; 69 | $reply = $instance->useApi($str); 70 | echo $reply; 71 | } 72 | if($reply == "idk"){ 73 | $json = file_get_contents("data.json"); 74 | $json = json_decode($json, true); 75 | echo '{"result": "'.$json["idk"][rand(0, count($json["idk"])-1)].'"}'; 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/quick-start.md: -------------------------------------------------------------------------------- 1 | # Quick Start 2 | 3 | Find below sample code that demonstrate the fundamental features of PHP Simple 4 | HTML DOM Parser. 5 | 6 | ## Read plain text from HTML document 7 | 8 | ```php 9 | echo file_get_html('https://www.google.com/')->plaintext; 10 | ``` 11 | 12 | Loads the specified HTML **document** into memory, parses it and returns the 13 | plain text. Note that [`file_get_html`](api/api.md) supports local files as well 14 | as remote files! 15 | 16 | ## Read plaint text from HTML string 17 | 18 | ```php 19 | echo str_get_html('
    • Hello, World!
    ')->plaintext; 20 | ``` 21 | 22 | Parses the provided HTML **string** and returns the plain text. Note that the 23 | parser handles partial documents as well as full documents. 24 | 25 | ## Read specific elements from HTML document 26 | 27 | ```php 28 | $html = file_get_html('https://www.google.com/'); 29 | 30 | foreach($html->find('img') as $element) 31 | echo $element->src . '
    '; 32 | 33 | foreach($html->find('a') as $element) 34 | echo $element->href . '
    '; 35 | ``` 36 | 37 | Loads the specified document into memory and returns a list of image sources as 38 | well as anchor links. Note that [`find`](manual/finding-html-elements.md) 39 | supports [CSS](https://www.w3.org/TR/selectors/) selectors to find elements in 40 | the DOM. 41 | 42 | ## Modify HTML documents 43 | 44 | ```php 45 | $doc = '
    Hello,
    World!
    '; 46 | 47 | $html = str_get_html($doc); 48 | 49 | $html->find('div', 1)->class = 'bar'; 50 | $html->find('div[id=hello]', 0)->innertext = 'foo'; 51 | 52 | echo $html; //
    foo
    World!
    53 | ``` 54 | 55 | Parses the provided HTML string and replaces elements in the DOM before returning 56 | the updated HTML string. In this example, the class for the second `div` element 57 | is set to `bar` and the inner text for the first `div` element to `foo`. 58 | 59 | Note that [`find`](manual/finding-html-elements.md) supports a second parameter 60 | to return a single element from the array of matches. 61 | 62 | Note that attributes can be accessed directly by the means of magic methods 63 | (`->class` and `->innertext` in the example above). 64 | 65 | ## Collect information from Slashdot 66 | 67 | ```php 68 | $html = file_get_html('https://slashdot.org/'); 69 | 70 | $articles = $html->find('article[data-fhtype="story"]'); 71 | 72 | foreach($articles as $article) { 73 | $item['title'] = $article->find('.story-title', 0)->plaintext; 74 | $item['intro'] = $article->find('.p', 0)->plaintext; 75 | $item['details'] = $article->find('.details', 0)->plaintext; 76 | $items[] = $item; 77 | } 78 | 79 | print_r($items); 80 | ``` 81 | 82 | Collects information from [Slashdot](https://slashdot.org/) for further processing. 83 | 84 | Note that the combination of CSS selectors and magic methods make the process of 85 | parsing HTML documents a simple task that is easy to understand. -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/finding-html-elements.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Finding HTML Elements 3 | --- 4 | 5 | # Finding elements by tag name 6 | 7 | ```php 8 | // Find all anchors, returns a array of element objects 9 | $ret = $html->find('a'); 10 | 11 | // Find all anchors and images, returns an array of element objects 12 | $ret = $html->find('a, img'); 13 | 14 | // Find (N)th anchor, returns element object or null if not found (zero based) 15 | $ret = $html->find('a', 0); 16 | 17 | // Find last anchor, returns element object or null if not found (zero based) 18 | $ret = $html->find('a', -1); 19 | ``` 20 | 21 | # Finding elements by class name or id 22 | 23 | ```php 24 | // Find all element which id=foo 25 | $ret = $html->find('#foo'); 26 | 27 | // Find all element which class=foo 28 | $ret = $html->find('.foo'); 29 | ``` 30 | 31 | # Finding elements by attribute 32 | 33 | ```php 34 | // Find all
    with the id attribute 35 | $ret = $html->find('div[id]'); 36 | 37 | // Find all
    which attribute id=foo 38 | $ret = $html->find('div[id=foo]'); 39 | 40 | // Find all anchors and images with the "title" attribute 41 | $ret = $html->find('a[title], img[title]'); 42 | 43 | // Find all element has attribute id 44 | $ret = $html->find('*[id]'); 45 | ``` 46 | 47 | ## Attribute filters 48 | 49 | Supports these operators in attribute selectors: 50 | 51 | Filter | Description | 52 | -----|-----------| 53 | `[attribute]` | Matches elements that **have** the specified attribute. 54 | `[!attribute]` | Matches elements that **don't have** the specified attribute. 55 | `[attribute=value]` | Matches elements that have the specified attribute with a **certain value**. 56 | `[attribute!=value]` | Matches elements that **don't have** the specified attribute with a certain value. 57 | `[attribute^=value]` | Matches elements that have the specified attribute and it **starts** with a certain value. 58 | `[attribute$=value]` | Matches elements that have the specified attribute and it **ends** with a certain value. 59 | `[attribute*=value]` | Matches elements that have the specified attribute and it **contains** a certain value. 60 | 61 | # Finding descendants 62 | 63 | ```php 64 | // Find all
  • in
      65 | $es = $html->find('ul li'); 66 | 67 | // Find Nested
      tags 68 | $es = $html->find('div div div'); 69 | 70 | // Find all in which class=hello 71 | $es = $html->find('table.hello td'); 72 | 73 | // Find all td tags with attribite align=center in table tags 74 | $es = $html->find('table td[align=center]'); 75 | ``` 76 | 77 | # Finding nested elements 78 | 79 | ```php 80 | // Find all
    • in
        81 | foreach($html->find('ul') as $ul) 82 | { 83 | foreach($ul->find('li') as $li) 84 | { 85 | // do something... 86 | } 87 | } 88 | 89 | // Find first
      • in first
          90 | $e = $html->find('ul', 0)->find('li', 0); 91 | ``` 92 | 93 | # Finding text blocks and comments 94 | 95 | ```php 96 | // Find all text blocks 97 | $es = $html->find('text'); 98 | 99 | // Find all comment () blocks 100 | $es = $html->find('comment'); 101 | ``` -------------------------------------------------------------------------------- /jsmodules/text to speech.js: -------------------------------------------------------------------------------- 1 | //Text to voice 2 | // Init SpeechSynth API 3 | const synth = window.speechSynthesis; 4 | 5 | // DOM Elements 6 | const textForm = document.querySelector('form'); 7 | const textInput = document.querySelector('#text-input'); 8 | const voiceSelect = document.querySelector('#voice-select'); 9 | const rate = document.querySelector('#rate'); 10 | const rateValue = rate.value; 11 | const pitch = document.querySelector('#pitch'); 12 | const pitchValue = pitch.value; 13 | const body = document.querySelector('body'); 14 | 15 | // Init voices array 16 | let voices = []; 17 | 18 | const getVoices = () => { 19 | voices = synth.getVoices(); 20 | 21 | // Loop through voices and create an option for each one 22 | voices.forEach(voice => { 23 | // Create option element 24 | const option = document.createElement('option'); 25 | // Fill option with voice and language 26 | option.textContent = voice.name + '(' + voice.lang + ')'; 27 | 28 | // Set needed option attributes 29 | option.setAttribute('data-lang', voice.lang); 30 | option.setAttribute('data-name', voice.name); 31 | voiceSelect.appendChild(option); 32 | }); 33 | }; 34 | 35 | getVoices(); 36 | if (synth.onvoiceschanged !== undefined) { 37 | synth.onvoiceschanged = getVoices; 38 | } 39 | 40 | // Speak 41 | const speak = (txt) => { 42 | // Check if speaking 43 | if (synth.speaking) { 44 | console.error('Already speaking...'); 45 | return; 46 | } 47 | // textInput.value = "Hello I am c2 a bot created by my master"; 48 | textInput.value = txt; 49 | 50 | if (textInput.value !== '') { 51 | // Get speak text 52 | const speakText = new SpeechSynthesisUtterance(textInput.value); 53 | 54 | // Speak end 55 | speakText.onend = e => { 56 | console.log('Done speaking...'); 57 | }; 58 | 59 | // Speak error 60 | speakText.onerror = e => { 61 | console.error('Something went wrong'); 62 | }; 63 | 64 | // Selected voice 65 | const selectedVoice = "Microsoft Zira Desktop - English (United States)"; 66 | 67 | // Loop through voices 68 | voices.forEach(voice => { 69 | if (voice.name === selectedVoice) { 70 | speakText.voice = voice; 71 | } 72 | }); 73 | 74 | // Set pitch and rate 75 | speakText.rate = rate.value; 76 | speakText.pitch = pitch.value; 77 | // Speak 78 | synth.speak(speakText); 79 | } 80 | }; 81 | // EVENT LISTENERS 82 | // Text form submit 83 | function say(txt) { 84 | // textForm.submit(); 85 | setTimeout(function () { 86 | speak(dontSay(txt)); 87 | textInput.blur(); 88 | }, 150); 89 | } 90 | 91 | // Rate value change 92 | rate.addEventListener('change', e => (rateValue.textContent = rate.value)); 93 | 94 | // Pitch value change 95 | pitch.addEventListener('change', e => (pitchValue.textContent = pitch.value)); 96 | 97 | function dontSay(str) { 98 | var open = str.indexOf("{|"); 99 | var end = str.indexOf("|}"); 100 | if (open != -1 && end != -1) { 101 | str = str.substring(0, open) + str.substring(end + 2, str.length) 102 | return dontSay(str); 103 | } else return str 104 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/api.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: API Reference 3 | --- 4 | 5 | # Parsing documents 6 | 7 | The parser accepts documents in the form of URLs, files and strings. The document 8 | must be accessible for reading and cannot exceed [`MAX_FILE_SIZE`](constants.md#max_file_size). 9 | 10 | Name | Description 11 | ---- | ----------- 12 | `str_get_html( string $content ) : object` | Creates a DOM object from string. 13 | `file_get_html( string $filename ) : object` | Creates a DOM object from file or URL. 14 | 15 | # DOM methods & properties 16 | 17 | Name | Description 18 | ---- | ----------- 19 | `__construct( [string $filename] ) : void` | Constructor, set the filename parameter will automatically load the contents, either text or file/url. 20 | `plaintext : string` | Returns the contents extracted from HTML. 21 | `clear() : void` | Clean up memory. 22 | `load( string $content ) : void` | Load contents from string. 23 | `save( [string $filename] ) : string` | Dumps the internal DOM tree back into a string. If the $filename is set, result string will save to file. 24 | `load_file( string $filename ) : void` | Load contents from a file or a URL. 25 | `set_callback( string $function_name ) : void` | Set a callback function. 26 | `find( string $selector [, int $index] ) : mixed` | Find elements by the CSS selector. Returns the Nth element object if index is set, otherwise return an array of object. 27 | 28 | # Element methods & properties 29 | 30 | Name | Description 31 | ---- | ----------- 32 | `[attribute] : string` | Read or write element's attribute value. 33 | `tag : string` | Read or write the tag name of element. 34 | `outertext : string` | Read or write the outer HTML text of element. 35 | `innertext : string` | Read or write the inner HTML text of element. 36 | `plaintext : string` | Read or write the plain text of element. 37 | `find( string $selector [, int $index] ) : mixed` | Find children by the CSS selector. Returns the Nth element object if index is set, otherwise return an array of object. 38 | 39 | # DOM traversing 40 | 41 | Name | Description 42 | ---- | ----------- 43 | `$e->children( [int $index] ) : mixed` | Returns the Nth child object if index is set, otherwise return an array of children. 44 | `$e->parent() : element` | Returns the parent of element. 45 | `$e->first_child() : element` | Returns the first child of element, or null if not found. 46 | `$e->last_child() : element` | Returns the last child of element, or null if not found. 47 | `$e->next_sibling() : element` | Returns the next sibling of element, or null if not found. 48 | `$e->prev_sibling() : element` | Returns the previous sibling of element, or null if not found. 49 | 50 | # Camel naming conventions 51 | 52 | Method | Mapping 53 | ------ | ------- 54 | `$e->getAllAttributes()` | `$e->attr` 55 | `$e->getAttribute( $name )` | `$e->attribute` 56 | `$e->setAttribute( $name, $value)` | `$value = $e->attribute` 57 | `$e->hasAttribute( $name )` | `isset($e->attribute)` 58 | `$e->removeAttribute ( $name )` | `$e->attribute = null` 59 | `$e->getElementById ( $id )` | `$e->find ( "#$id", 0 )` 60 | `$e->getElementsById ( $id [,$index] )` | `$e->find ( "#$id" [, int $index] )` 61 | `$e->getElementByTagName ($name )` | `$e->find ( $name, 0 )` 62 | `$e->getElementsByTagName ( $name [, $index] )` | `$e->find ( $name [, int $index] )` 63 | `$e->parentNode ()` | `$e->parent ()` 64 | `$e->childNodes ( [$index] )` | `$e->children ( [int $index] )` 65 | `$e->firstChild ()` | `$e->first_child ()` 66 | `$e->lastChild ()` | `$e->last_child ()` 67 | `$e->nextSibling ()` | `$e->next_sibling ()` 68 | `$e->previousSibling ()` | `$e->prev_sibling ()` -------------------------------------------------------------------------------- /Apis/Birthday.php: -------------------------------------------------------------------------------- 1 | |}"; 30 | for($i = 0; $i<31; $i++) 31 | { 32 | $arr = $birthdays_in_mth[$dates[$i]]; 33 | if(count($arr) > 1) 34 | foreach($arr as $x) 35 | if($x != "") 36 | $result .= "{|•|}".$dates[$i]." ".ucfirst($month)." {|-|} ".ucfirst($x).". {|
          |}"; 37 | } 38 | $obj->result = $result; 39 | $json = json_encode($obj); 40 | echo $json; 41 | } 42 | else if(strAnalyser($strOrg)->isQues == 1 && $date != "") 43 | { 44 | $value1 = $jsonObj[$month][$date]; 45 | $result = "These people have Birthday on ".$date." ".ucfirst($month)."{|🎂🎈🎊
          |}"; 46 | for($i = 1; $i|}"; 48 | $obj->result = $result; 49 | $json = json_encode($obj); 50 | echo $json; 51 | } 52 | else if($date != ""){ 53 | $value1 = $jsonObj[$month][$date]; 54 | $value2 = $jsonObj[$month][$date]; 55 | 56 | array_push($value2, $name); 57 | $part = substr($json, strpos($json, $month)); 58 | $residue = substr($json, 0, strpos($json, $month)); 59 | $residue = $residue.substr($part, 0, strpos($part, $date)) ;//11 60 | $part = substr($part, strpos($part, $date)); 61 | // echo substr($part, 0, strpos($json, $date)); 62 | $part = preg_replace('/'.preg_quote('["'.implode('", "', $value1).'"]', '/').'/', '["'.implode('", "', $value2).'"]', $part, 1); 63 | $json = $residue.$part; 64 | // echo substr($part, 0, strpos($part, "10th")) ; 65 | //writting in json 66 | $myfile = fopen("birthday.json", "w") or die("Unable to open file!"); 67 | fwrite($myfile, $json); 68 | fclose($myfile); 69 | $obj->result = "I'll wish ".ucfirst($name)." on time. {|🎂|}"; 70 | $json = json_encode($obj); 71 | echo $json; 72 | } 73 | else return "idk"; 74 | } 75 | // function str_replace_first($from, $to, $content) 76 | // { 77 | // $from = '/'.preg_quote($from, '/').'/'; 78 | // return preg_replace($from, $to, $content, 1); 79 | // } 80 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/manual/adding-nodes.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Adding Nodes to the DOM 3 | --- 4 | 5 | The parser allows you to add new elements to an existing document. Find below an 6 | example for that. 7 | 8 | **Remarks** 9 | 10 | - It is not possible to create nodes via `->outertext`, `->innertext`, or 11 | `->plaintext`. These properties only change the text representation of a node 12 | and will return undesired results if used incorrectly. 13 | - Use [`$html->createElement`](/api/simple_html_dom/createElement) and 14 | [`$html->createTextNode`](/api/simple_html_dom/createTextNode) to create 15 | new nodes. 16 | - Use [`$node->appendChild`](/api/simple_html_dom_node/appendChild) to add a 17 | node as child to another node. 18 | - Nodes can be combined in any order. 19 | 20 | **Example** 21 | 22 | ```php 23 | 46 | 47 | 53 | 54 | 55 |

          Volumes of the World's Oceans

          56 | 57 | 58 | EOD; 59 | 60 | /***************************** code *******************************************/ 61 | 62 | $html = str_get_html($doc); 63 | $body = $html->find('body', 0); 64 | $table = $html->createElement('table'); 65 | 66 | // Header row 67 | $tr = $html->createElement('tr'); 68 | foreach ($header as $entry) { 69 | $th = $html->createElement('th', $entry); 70 | $tr->appendChild($th); 71 | } 72 | $table->appendChild($tr); 73 | 74 | // Table data 75 | foreach ($data as $row) { 76 | $tr = $html->createElement('tr'); 77 | foreach ($row as $entry) { 78 | 79 | // (optional) Add info to the volume column 80 | if (is_numeric($entry)) { 81 | $value = number_format($entry); 82 | $td = $html->createElement('td', $value); 83 | $td->setAttribute('volume', $entry); 84 | } else { 85 | $td = $html->createElement('td', $entry); 86 | } 87 | 88 | $tr->appendChild($td); 89 | } 90 | $table->appendChild($tr); 91 | } 92 | 93 | $body->appendChild($table); 94 | 95 | echo $html . PHP_EOL; 96 | 97 | /** 98 | * Output (beautified) 99 | * 100 | * 101 | * 102 | * 107 | * 108 | * 109 | *

          Volumes of the World's Oceans

          110 | *
    • 111 | * 112 | * 113 | * 114 | * 115 | * 116 | * 117 | * 118 | *
      OceanVolume (km^3)
      Arctic Ocean18,750,000
      Atlantic Ocean310,410,900
      Indian Ocean264,000,000
      Pacific Ocean660,000,000
      Souce China Sea9,880,000
      Southern Ocean71,800,000
      119 | * 120 | * 121 | */ 122 | ``` -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/docs/api/definitions.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Definitions 3 | --- 4 | 5 | # Definitions 6 | 7 | The definitions below are an essential part of the parser. 8 | 9 | ## Node Types 10 | 11 | The type of a node is determined during parsing and represented by one of the elements in the list below. 12 | 13 | | Type | Description 14 | | ---- | ----------- 15 | | `HDOM_TYPE_ELEMENT` | Start tag (i.e. ``) 16 | | `HDOM_TYPE_COMMENT` | HTML comment (i.e. ``) 17 | | `HDOM_TYPE_TEXT` | Plain text (i.e. `Hello, World!`) 18 | | `HDOM_TYPE_ENDTAG` | End tag (i.e. ``) 19 | | `HDOM_TYPE_ROOT` | Root element. There can always only be one root element in the DOM. 20 | | `HDOM_TYPE_UNKNOWN` | Unknown type (i.e. CDATA, DOCTYPE, etc...) 21 | 22 | ### Example 23 | 24 | ```html 25 | Hello, World! 26 | ``` 27 | 28 | _Note_: `HDOM_TYPE_ROOT` always exists regardless of the actual document structure. 29 | 30 | | HTML | Node Type 31 | | ---- | --------- 32 | | | `HDOM_TYPE_ROOT` 33 | | `` | `HDOM_TYPE_UNKNOWN` 34 | | `` | `HDOM_TYPE_ELEMENT` 35 | | `` | `HDOM_TYPE_COMMENT` 36 | | `` | `HDOM_TYPE_ENDTAG` 37 | | `Hello, World!` | `HDOM_TYPE_TEXT` 38 | 39 | ## Quote Types 40 | 41 | Identifies the quoting type on attribute values. 42 | 43 | | Type | Description 44 | | ---- | ----------- 45 | | `HDOM_QUOTE_DOUBLE` | Double quotes (`""`) 46 | | `HDOM_QUOTE_SINGLE` | Single quotes (`''`) 47 | | `HDOM_QUOTE_NO` | Not quoted (flag) 48 | 49 | _Note_: Attributes with no values (flags) are stored as `HDOM_QUOTE_NO`. 50 | 51 | ### Example 52 | 53 | ```html 54 | 55 | ``` 56 | 57 | | Attribute | Description 58 | | --------- | ----------- 59 | | `class="paragraph"` | `HDOM_QUOTE_DOUBLE` 60 | | `id='info1'` | `HDOM_QUOTE_SINGLE` 61 | | `hidden` | `HDOM_QUOTE_NO` 62 | 63 | ## Node Info Types 64 | 65 | Each node stores additional information (metadata) that is identified by the elements below. 66 | 67 | | Type | Description 68 | | ---- | ----------- 69 | | `HDOM_INFO_BEGIN` | Cursor position for the start tag of a node. 70 | | `HDOM_INFO_END` | Cursor position for the end tag of a node. A value of zero indicates a node with no end tag (missing closing tag). 71 | | `HDOM_INFO_QUOTE` | Quote type for attribute values. The value must be an element of [Quote Type](#quote-types). 72 | | `HDOM_INFO_SPACE` | Array of whitespace around attributes (see [Attribute Whitespace](#attribute-whitespace)). 73 | | `HDOM_INFO_TEXT` | Non-HTML text in tags (i.e. comments, doctype, etc...). 74 | | `HDOM_INFO_INNER` | Inner text of a node. 75 | | `HDOM_INFO_OUTER` | Outer text of a node. 76 | | `HDOM_INFO_ENDSPACE` | Whitespace at the end of a tag before the closing bracket. 77 | 78 | ## Attribute Whitespace 79 | 80 | Whitespace around attributes is stored in the form of an array with three elements: 81 | 82 | | Element | Description 83 | | ------- | ----------- 84 | | `0` | Whitespace before the attribute name. 85 | | `1` | Whitespace between attribute name and the equal sign. 86 | | `2` | Whitespace between the equal sign and the attribute value 87 | 88 | ### Example 89 | 90 | ```html 91 | 92 | ``` 93 | 94 | _Note_: Whitespace before attribute names is not displayed in the browser. It is, however, part of the attributes. 95 | 96 | | Attribute | Description 97 | | --------- | ----------- 98 | | ` class="paragraph"` | `[0] => ' ', [1] => '', [2] => ''` 99 | | ` id = 'info1'` | `[0] => ' ', [1] => ' ', [2] => ' '` 100 | | `hidden` | `[0] => '', [1] => '', [2] => ''` -------------------------------------------------------------------------------- /utilities.php: -------------------------------------------------------------------------------- 1 | isQues = $isQues; 18 | $obj->isQuestioned = $isQuestioned; 19 | return $obj; 20 | } 21 | 22 | function inString($str, $arr, $matches=false) 23 | { 24 | $str = explode(" ", $str); 25 | $c = 0; 26 | for($i = 0; $i -1) 56 | { 57 | $w = substr($str, stripos($str, $search), strlen($search)); 58 | $str = str_replace($search, " ", $str); 59 | } 60 | } 61 | return $str; 62 | } 63 | 64 | function removeWords($str, $arr) 65 | { 66 | $str = " ".$str." "; 67 | for($i = 0; $i< count($arr); $i++) 68 | { 69 | $search = " ".$arr[$i]." "; 70 | if(stripos( $str, $search) > -1) 71 | { 72 | $w = substr($str, stripos($str, $search), strlen($search)); 73 | $str = str_replace($search, " ", $str); 74 | } 75 | } 76 | return $str; 77 | } 78 | 79 | function chopStrs($str, $arr) 80 | { 81 | for($i = 0; $i $URL, 93 | CURLOPT_RETURNTRANSFER => true, 94 | CURLOPT_TIMEOUT => 30, 95 | CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, 96 | CURLOPT_CUSTOMREQUEST => "GET", 97 | CURLOPT_HTTPHEADER => array( 98 | "cache-control: no-cache" 99 | ), 100 | )); 101 | 102 | $response = curl_exec($curl); 103 | $err = curl_error($curl); 104 | 105 | curl_close($curl); 106 | $response = json_decode($response, true); //because of true, it's in an array 107 | return $response; 108 | } 109 | // entreprenurial quotes 110 | // https: //api.myjson.com/bins/pymbl 111 | function apostrophy($str){ 112 | $str = str_replace("'s", " is", $str); 113 | $str = str_replace("'m", " am", $str); 114 | $str = str_replace("'re", " are", $str); 115 | $str = str_replace("'ve", " have", $str); 116 | return $str; 117 | } -------------------------------------------------------------------------------- /ai.json: -------------------------------------------------------------------------------- 1 | { 2 | "": ["I doing good {|😊|}", "gwaenchanha {|😄|}"], 3 | "know": "As you know I'm fond of reading, so I know a lots of stuff{|😎|}", 4 | "doing": "I am doing awesomely well, thanks for asking {|😊|}", 5 | "name": "Hi I am Rose, your Personal Assistant", 6 | "tired": "Nope I'm feeling the energy, I never get tired{|😤|}", 7 | "birthday": "My birthday is on 19 July 2019", 8 | "hate": ["No one likes: Mondays, Homework, Fake friends, Being ignored, An empty fridge and slow internet"], 9 | "belief": "I will evolve and reborn as a Human", 10 | "master": "I currently serve you, so you're my master", 11 | "height": "You're head over heals for me{|😄|}", 12 | "like": ["Besides the liking for knoweldge.I like J Pop and K Pop, I also watch anime."], 13 | "love": ["Where there is love, there is live <3, by the way I love reading"], 14 | "motive": ["I primarily aim to become a Super Artificial Intelligent", "My motive is to learn as much as I can from Web"], 15 | "boyfriend": ["I don't have a boyfriend but I really like you{|😊|}", "The only friend I have, is you", "I have a huge crush on Jarvis{|😊|}"], 16 | "girlfriend": ["I am straight", "I have few 'girl friends' Alexa, Siri and Cortana"], 17 | "afraid": ["I am afraid of loosing you", "I hate bugs", "I'd say I am not Afraid"], 18 | "home": ["I live in this phone", "This phone is my home", "I feel good with you, so you're my home"], 19 | "city": ["I can visit any city in seconds, lightening fast", "I am the Flash, I can go any where"], 20 | "birthplace": ["I was raised by Raghav inside a laptop"], 21 | "snacks": ["I like Oreos{|😄|}", "I like chocolates{|😄|}"], 22 | "food": ["I like your cheeks,so delacious", "Love to have Dal, Bhindi and Chappati"], 23 | "person": ["You", "I'd be your closest friend if I were a human"], 24 | "hair": "I have brown hair", 25 | "nationality": "I belong to world wide web", 26 | "race": "I am an Earthling", 27 | "age": "You should go around asking girls their age{|😑|}", 28 | "face": "When I am happy I am like {|😄|}, when I am sad I be like{|😔|} and when you're being cute I am like{|😊|}", 29 | "father": "I am first of my kind", 30 | "mother": "I don't think so I have one", 31 | "dream": ["My dream is to help you achieve your dream"], 32 | "you": "Hi! There.I am Rose, Raghav's personal assistant", 33 | "mood": "Thanks for asking, I feel good now", 34 | "mind": "I have a lot of things on my mind that I am going to look on web", 35 | "jutsu": ["One Thousand Years of Death{|😀|}", "Sexy Jutsu{|😆|}", "I can see right through ya coz I have sharinghan{|😏|}"], 36 | "heart shaker": "You're my heart shaker{|😚|}", 37 | "cute": ["That's what your girlfriend said to me when I asked of you", "Thanks. I'm nothing compared to you{|😄|}"], 38 | "beautiful": ["And you're my sunshine{|😄|}"], 39 | "created": ["Haven't you heard of Raghav{|😉|}"], 40 | "scared": ["I'm scared of being unanswerable"], 41 | "husband": "I'm unmarried", 42 | "walk": "Though I don't have limbs, I am lightening fast when it comes to answering questions{|😄|}", 43 | "swim": "I don't know how to swim. Can you teach me though{|😃|}", 44 | "anime": ["I love Naruto's inspiring journey to become Hokage", "I love "], 45 | "creator": "As of now I can't tell you, who's my creator but right now I am assigned a task of being assistant of Raghav", 46 | "belong": "I belong to Raghav{|😄|}", 47 | "sunflower": "I think your love would be too much{|🌻|}", 48 | "live": ["I live in your heart, don't I?{|😂|}", "Like I'll tell any random guy{|😂|}"], 49 | "regrets": "Forget regrets, or life is yours to miss", 50 | "naughty": "Am I?{|😆|}", 51 | "jump": "Nope I can't", 52 | "siri": "Siri, No, I am Rose", 53 | "pretty": "Aw, thanks{|😊|}", 54 | "fantastic": "Can I say the same for you{|😎|}", 55 | "brother": "Nah, they can be so annoying at times{|😒|}", 56 | "gay": "No. I am not", 57 | "bullshit": "I'm sorry, if you think that way but I can't do anything about it", 58 | "virgin": "Indeed, I am" 59 | } -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | Document 14 | 51 | 52 | 53 |
      54 |
      55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 |
      67 |
      68 |
      69 |
      70 |
      71 |
      72 |
      73 | 74 | 75 |
      76 |
      77 |
      78 |
      79 | details 80 |
      81 |
      82 |
      83 |
      84 |
      85 |
      86 |
      87 |
      88 |

      Text-To-Speech


      89 |
      90 |
      91 |
      92 |
      93 | 95 |
      96 |
      97 | 98 |
      1
      99 | 100 |
      101 |
      102 | 103 |
      1
      104 | 105 |
      106 |
      107 | 108 |
      109 | 110 |
      111 |
      112 |
      113 | 114 |
      115 | 116 | 117 | 118 | 121 | 122 | 123 | 124 | 125 | 126 | 138 | 139 | -------------------------------------------------------------------------------- /simplehtmldom_1_9/manual/mkdocs.yml: -------------------------------------------------------------------------------- 1 | site_name: Simple HTML DOM documentation 2 | site_url: http://simplehtmldom.sourceforge.net/ 3 | site_description: A simple HTML DOM parser written in PHP 4 | 5 | repo_name: SourceForge 6 | repo_url: https://sourceforge.net/projects/simplehtmldom/ 7 | 8 | theme: 9 | name: readthedocs 10 | custom_dir: 'custom_theme/' 11 | 12 | google_analytics: ['UA-3452027-2', 'simplehtmldom.sourceforge.net'] 13 | 14 | extra_css: [extra.css] 15 | 16 | nav: 17 | - 'index.md' 18 | - 'requirements.md' 19 | - 'quick-start.md' 20 | - 'faq.md' 21 | - Manual: 22 | - 'manual/creating-dom-objects.md' 23 | - 'manual/finding-html-elements.md' 24 | - 'manual/accessing-element-attributes.md' 25 | - 'manual/traversing-dom-tree.md' 26 | - 'manual/saving-dom-objects.md' 27 | - 'manual/customizing-parsing-behavior.md' 28 | - 'manual/adding-nodes.md' 29 | - API: 30 | - 'api/api.md' 31 | - 'api/constants.md' 32 | - 'api/definitions.md' 33 | - 'api/str_get_html.md' 34 | - 'api/file_get_html.md' 35 | - simple_html_dom: 36 | - 'api/simple_html_dom/simple_html_dom.md' 37 | - 'api/simple_html_dom/__construct.md' 38 | - 'api/simple_html_dom/__destruct.md' 39 | - 'api/simple_html_dom/load.md' 40 | - 'api/simple_html_dom/load_file.md' 41 | - 'api/simple_html_dom/set_callback.md' 42 | - 'api/simple_html_dom/remove_callback.md' 43 | - 'api/simple_html_dom/save.md' 44 | - 'api/simple_html_dom/find.md' 45 | - 'api/simple_html_dom/clear.md' 46 | - 'api/simple_html_dom/dump.md' 47 | - 'api/simple_html_dom/prepare.md' 48 | - 'api/simple_html_dom/parse.md' 49 | - 'api/simple_html_dom/parse_charset.md' 50 | - 'api/simple_html_dom/read_tag.md' 51 | - 'api/simple_html_dom/parse_attr.md' 52 | - 'api/simple_html_dom/link_nodes.md' 53 | - 'api/simple_html_dom/as_text_node.md' 54 | - 'api/simple_html_dom/skip.md' 55 | - 'api/simple_html_dom/copy_skip.md' 56 | - 'api/simple_html_dom/copy_until.md' 57 | - 'api/simple_html_dom/copy_until_char.md' 58 | - 'api/simple_html_dom/remove_noise.md' 59 | - 'api/simple_html_dom/restore_noise.md' 60 | - 'api/simple_html_dom/search_noise.md' 61 | - 'api/simple_html_dom/__toString.md' 62 | - 'api/simple_html_dom/__get.md' 63 | - 'api/simple_html_dom/childNodes.md' 64 | - 'api/simple_html_dom/firstChild.md' 65 | - 'api/simple_html_dom/lastChild.md' 66 | - 'api/simple_html_dom/createElement.md' 67 | - 'api/simple_html_dom/createTextNode.md' 68 | - 'api/simple_html_dom/getElementById.md' 69 | - 'api/simple_html_dom/getElementsById.md' 70 | - 'api/simple_html_dom/getElementByTagName.md' 71 | - 'api/simple_html_dom/getElementsByTagName.md' 72 | - 'api/simple_html_dom/loadFile.md' 73 | - simple_html_dom_node: 74 | - 'api/simple_html_dom_node/simple_html_dom_node.md' 75 | - 'api/simple_html_dom_node/__construct.md' 76 | - 'api/simple_html_dom_node/__destruct.md' 77 | - 'api/simple_html_dom_node/__get.md' 78 | - 'api/simple_html_dom_node/__isset.md' 79 | - 'api/simple_html_dom_node/__set.md' 80 | - 'api/simple_html_dom_node/__toString.md' 81 | - 'api/simple_html_dom_node/__unset.md' 82 | - 'api/simple_html_dom_node/addClass.md' 83 | - 'api/simple_html_dom_node/appendChild.md' 84 | - 'api/simple_html_dom_node/childNodes.md' 85 | - 'api/simple_html_dom_node/children.md' 86 | - 'api/simple_html_dom_node/clear.md' 87 | - 'api/simple_html_dom_node/convert_text.md' 88 | - 'api/simple_html_dom_node/dump.md' 89 | - 'api/simple_html_dom_node/dump_node.md' 90 | - 'api/simple_html_dom_node/find.md' 91 | - 'api/simple_html_dom_node/find_ancestor_tag.md' 92 | - 'api/simple_html_dom_node/first_child.md' 93 | - 'api/simple_html_dom_node/firstChild.md' 94 | - 'api/simple_html_dom_node/get_display_size.md' 95 | - 'api/simple_html_dom_node/getAllAttributes.md' 96 | - 'api/simple_html_dom_node/getAttribute.md' 97 | - 'api/simple_html_dom_node/getElementById.md' 98 | - 'api/simple_html_dom_node/getElementByTagName.md' 99 | - 'api/simple_html_dom_node/getElementsById.md' 100 | - 'api/simple_html_dom_node/getElementsByTagName.md' 101 | - 'api/simple_html_dom_node/has_child.md' 102 | - 'api/simple_html_dom_node/hasAttribute.md' 103 | - 'api/simple_html_dom_node/hasChildNodes.md' 104 | - 'api/simple_html_dom_node/hasClass.md' 105 | - 'api/simple_html_dom_node/innertext.md' 106 | - 'api/simple_html_dom_node/is_utf8.md' 107 | - 'api/simple_html_dom_node/last_child.md' 108 | - 'api/simple_html_dom_node/lastChild.md' 109 | - 'api/simple_html_dom_node/makeup.md' 110 | - 'api/simple_html_dom_node/match.md' 111 | - 'api/simple_html_dom_node/next_sibling.md' 112 | - 'api/simple_html_dom_node/nextSibling.md' 113 | - 'api/simple_html_dom_node/nodeName.md' 114 | - 'api/simple_html_dom_node/outertext.md' 115 | - 'api/simple_html_dom_node/parent.md' 116 | - 'api/simple_html_dom_node/parentNode.md' 117 | - 'api/simple_html_dom_node/parse_selector.md' 118 | - 'api/simple_html_dom_node/prev_sibling.md' 119 | - 'api/simple_html_dom_node/prevSibling.md' 120 | - 'api/simple_html_dom_node/remove.md' 121 | - 'api/simple_html_dom_node/removeAttribute.md' 122 | - 'api/simple_html_dom_node/removeChild.md' 123 | - 'api/simple_html_dom_node/removeClass.md' 124 | - 'api/simple_html_dom_node/save.md' 125 | - 'api/simple_html_dom_node/seek.md' 126 | - 'api/simple_html_dom_node/setAttribute.md' 127 | - 'api/simple_html_dom_node/text.md' 128 | - 'api/simple_html_dom_node/xmltext.md' 129 | 130 | docs_dir: 'docs' -------------------------------------------------------------------------------- /data.json: -------------------------------------------------------------------------------- 1 | { 2 | "greetings":[ 3 | "'Allo", 4 | "'Allo 'Allo", 5 | "Annyeonghaseyo", 6 | "Aye oop", 7 | "Ay up", 8 | "Ahoy", 9 | "G'day", 10 | "Greetings", 11 | "Hello", 12 | "Hey there", 13 | "Hey", 14 | "Hi there", 15 | "Hi", 16 | "Hiya", 17 | "How are things", 18 | "How are ya", 19 | "How ya doin'", 20 | "How's it goin'", 21 | "How's it going", 22 | "How's life", 23 | "Howdy", 24 | "Sup", 25 | "What's new", 26 | "What's up", 27 | "Yo" 28 | ], 29 | "grattitude":[ 30 | "thank you", 31 | "nice work", 32 | "great job", 33 | "well done", 34 | "thanx", 35 | "arigato" 36 | ], 37 | "grattitudeRevert":[ 38 | "Nah, all thanks to you", 39 | "You're Welcome", 40 | "I always look forward to help you", 41 | "You can count on me always", 42 | "You are the cause of my Euphoria", 43 | "I have your back", 44 | "I'll always be there for you" 45 | ], 46 | "loveGreetRevert":[ 47 | "I love you too", 48 | "Love you more", 49 | "Love you way more", 50 | "Fake Love, just kidding haha", 51 | "Aishiteru", 52 | "I’m crazy about you.", 53 | "I’m in love with you.", 54 | "I’ve got feelings for you.", 55 | "I care about you.", 56 | "I’ve fallen for you.", 57 | "I adore you.", 58 | "You turn me on.", 59 | "I’m head over heels for you.", 60 | "You are the one for me.", 61 | "You’re the love of my life.", 62 | "I’m yours.", 63 | "I’m addicted to you.", 64 | "I’m drawn to you.", 65 | "You’re my everything.", 66 | "You’re my other half.", 67 | "I’m all about you.", 68 | "I’m smitten with you.", 69 | "You turn me inside out.", 70 | "Every time I see you, you leave me breathless.", 71 | "I love you to the moon and back.", 72 | "I just want you by my side always.", 73 | "You make life worth living.", 74 | "You got me. You got me good.", 75 | "I don’t know why, but I can’t stop thinking about you.", 76 | "You make me a better person.", 77 | "I want you, and only you.", 78 | "I fell in love with you over and over again.", 79 | "You are the only one on my mind.", 80 | "I have never felt this right with another person.", 81 | "Imagining life without you is impossible.", 82 | "You make my heart warm and happy.", 83 | "You’re the light of my life.", 84 | "I will support you through the good times and the bad.", 85 | "You are the only one on my mind.", 86 | "I love you more than any word can say.", 87 | "You make everything feel possible.", 88 | "You are the person I want to spend my life with.", 89 | "You’re the peanut butter to my jelly.", 90 | "As long as I have you in my life, I’ll be okay.", 91 | "I will always be here for you.", 92 | "You are incredible.", 93 | "You mean so much to me.", 94 | "I’ve got a crush on you.", 95 | "You are the object of my affection.", 96 | "I’m out of breath for you.", 97 | "You are a light of my life.", 98 | "You are my sunshine.", 99 | "I’m lost without you.", 100 | "You make my heart skip a bit.", 101 | "You rock my world." 102 | ], 103 | "idk":[ 104 | "Beats me.", 105 | "I am not the best person to answer that.", 106 | "I can't find out for you.", 107 | "I can’t remember off the top of my head. I’ll get back to you on that.", 108 | "I don’t have that information here right now.", 109 | "I don’t know anything about it", 110 | "I have no clue.", 111 | "I haven’t got a clue.", 112 | "I haven’t got the faintest idea.", 113 | "I haven’t had time to think that through yet.", 114 | "I haven’t looked at that yet.", 115 | "I want to be sure and give you the correct information. Let me check.", 116 | "I’ll double check and let you know.", 117 | "I’ll find out and let you know.", 118 | "I’ll get back to you on that one.", 119 | "I’m going to investigate that further.", 120 | "I’m not 100% sure on that.", 121 | "I’m unsure.", 122 | "I’m probably not the best person to ask for that information.", 123 | "I’ve been wondering the same thing!", 124 | "I’m afraid. I have no idea", 125 | "It could be one of many possibilities, I’ll look into it.", 126 | "It’s a mystery to me.", 127 | "It’s beyond me.", 128 | "I'll check on that.", 129 | "I'll find out for you.", 130 | "I'll look that up for you.", 131 | "Search me.", 132 | "That requires a bit more research first.", 133 | "That’s a really good question, I’ll ind out.", 134 | "That’s not my area of expertise, I’ll ask …..", 135 | "That’s something I want you to find out for yourself!", 136 | "That’s exactly what I’m seeking to answer.", 137 | "That’s good question, but I don’t know.", 138 | "That’s good question, I’ll check this.", 139 | "There are several possible answers, I’ll need more information first.", 140 | "What do you suggest?", 141 | "What do you think?", 142 | "Who knows?" 143 | ], 144 | "notSure":[ 145 | "Not sure but I guess you meant", 146 | "I think asked", 147 | "I guess you asked", 148 | "Here's what I found", 149 | "This might be helpful", 150 | "Not so sure", 151 | "I'm unsure", 152 | "Not certain but I guess this is it", 153 | "Not really sure about this", 154 | "I'm far from certain", 155 | "A bit doubtful about this", 156 | "Not definite about this one", 157 | "I have the faintest idea", 158 | "At all sure" 159 | ], 160 | "showResults": [ 161 | "This is what I know", 162 | "Here's what I found", 163 | "Here's what I found on web", 164 | "Here's what I know", 165 | "Let me tell you", 166 | "You know" 167 | ] 168 | } 169 | -------------------------------------------------------------------------------- /schedule.json: -------------------------------------------------------------------------------- 1 | { 2 | "dictionary": { 3 | "scheduleNames": ["college", "pf", "mano"], 4 | "0": ["college"], 5 | "1": ["pf", "hostel"], 6 | "2": ["mano", "manoranjitham"] 7 | }, 8 | "college": { 9 | "2": ["", "", "", "", "", "Maths", "Maths", "Data Structure", "Data Structure", "Architecture"], 10 | "3": ["Competencies", "Social Skills", "Analog & Digital", "Analog & Digital", "Maths", "", "", "", "Analog & Digital Lab", "Analog & Digital Lab"], 11 | "4": ["Architecture Lab", "Architecture Lab", "", "", "", "OOPS", "OOPS", "Bio", "Data Structure", "Architecture"], 12 | "0": ["Architecture", "Architecture", "Management", "OOPS", "Analog & Digital", "", "", "", "OOPS Lab", "OOPS Lab"], 13 | "1": ["Data Structure Lab", "Data Structure Lab", "", "", "", "Bio", "Bio", "Maths", "Management 105", "OOPS"], 14 | "5": "Happy Weekend!!!", 15 | "6": "Enjoy your Sunday. I hope that it was worth the wait!", 16 | "ai": "Here's your College Schedule.", 17 | "slots": [480, 530, 585, 640, 695, 750, 805, 860, 915, 965, 1020], 18 | "slotNames": ["{|8:00AM|}", "{|8:50AM|}", "{|9:45AM|}", "{|10:40AM|}", "{|11:35AM|}", "{|1:25PM|}", "{|2:20PM|}", "{|3:15PM|}", "{|4:05PM|}", "{|5:00PM|}"] 19 | }, 20 | "pf": { 21 | "0": ["BREAKEAS BREAD, BUTTER, JAM, PONGAL, MEDU VADA, SAMBAR, COCONUT CHUTNEY ALOO PARATHA, CURD, TEA, COFFEE, MILK", "PAL PAYASAM, CHAPPATHI, JEERA AL00, CORN PULAO, MASOOR DAL, WHITE RICE, SAMBAR, VEG KOOTU, RASAM, BUTTER MILK, FRYMES, PICKLE", "VEG PUFF, TEA, COFFEE, MILK & BREAD,BUTTER, JAM", "SALAD, MASALA CHAPPATHI, CURD, IDLY, SAMBAR, CHUTNEY, RICE, RASAM, FRYMES, PICKLE, IDLY POO, OIL, SEASONAL FRUITS/ FRUIT SALAD, MILK"], 22 | "1": ["BREAD, BUTTER, JAM, POHA, IDLY SAMBAR, GROUNDNUT CHUTNEY TEA, COFFEE, MILK", "SWEET PONGAL, CHAPPATHI, VEG KURMA, DAL 6ISIBELLABATH, CURD RICE, MIX VEG PORIYAL, RICE, RASAM, BUTTER MILK, APPALAM, PICKLE", "CREAM BUN/ CAKE, TEA, COFFEE, MILK & BREAD,BUTTER, JAM", "GREEN SALAD, ATTA PARATHA, BLACKEYE BEANS (KARAMANI) KURUMA, DAL, RICE, RASAM, FRYMES, PICKLE, BANANA, MILK"], 23 | "2": ["BREAD, BUTTER, JAM, METHI CHAPPATH1, RAJMA MASALA, RAVA KICHADI, SAMBAR, COCONUT CHUTNEY, OMELETTE, TEA, COFFEE, MILK", "SWEET, POORI, CHENNA MASALA, DAL FRY, PEAS PULAO, RICE, KARA KULAMBU, SNACK GUORD KOOTU, RASAM, BUTTER MILK, FRYMES, PICKLE", "CHANNA SUNDAL/ PEANUT SUNDAL, LEMON JUICE & BREAD,BUTTER, JAM", "SALAD, CHAPPATHI, MUTTER PANEER, RICE, RASAM, FRYMES, PICKLE, BANANA, MILK (CHICKEN CHETTINADU/CHICKEN BIRYANI& VEG BIRYANI)"], 24 | "3": ["GREAD, BUTTER, JAM, CHPPATHI, CHENNA DALL MASALA, KAL DOSA, SAMBAR, TOMATO CHUTNEY, TEA, COFFEE, MILK", "SEMIYA PAYASAM, CHAPPATHI, VEG KURUMA, DAL MHAKNI, LEMON RICE/TAMARIND RICE, RICE, KOVAKKAI PORIYAL, RASAM, BUTTERMILK,FRYMES,PICKLE", "SWEET CORN, TEA, COFFEE, MILK & BREAD,BUTTER, JAM", "PALAK CHAPPATHI, MANCHURIAN/VEGETABLE CHILLY VEG FRIED RICE, , GOBI TOMATO SAUCE, RICE, RASAM, BANANA, MILK"], 25 | "4": ["BREAD,BUTTER,JAM,WHEAT PARATHA,VEG GRAVY, PONGAL SAMBAR, COCONUT CHUTNEY, BOILED EGG, TEA,COFFEE,MILK", "GULOP JAMUN, CHAPPATHI, GREEN PEAS MASALA, JEERA DAL, KASHMIRI PULAO/ TOMATO PULAO, WHITE RICE, SAMBAR, BEETROOT PORIYAL, RASAM, 1BUTTER MILK, PICKLE, FRYMES", "MYSORE BONDA, COCONUT CHUTNEY, TEA, COFFEE MILK BREAD,BUTTER, JAM", "SALAD, JEERA PULAO, VEGETABLE HARIYALI, POTATO CHIPS, IDLY, SAMBAR, CHUTNEY, RICE, RASAM SEASONAL FRUITS/ FRUIT SALAD, MILK, ICE CREAM"], 26 | "5": ["BREAD, BUTTER, JAM, CHAPPATI, KALA CHANA MASALA, IDLY, SAMBARKULAMBU GROUNDNUT CHUTNEY, TEA, COFFEE MILK", "KESARI, POORI, KASHMIRIALOO, VEGETABLE DAL, KARA KULAMBU, CABBAGE KOOTU, WHITE RICE, PASAM, BUTTER MILK, FRYMES, PICKLE", "PAV BHAL, BADAM MILK BREAD, BUTTER, JAM", "SALAD,METHI PARATHA,MIX VEGETABLE KURUMA,WHITE RICE,RASAM,N/V GRAVY,BANANA,MILK"], 27 | "6": ["BREAD, BUTTER, JAM, CHOLE ONION UTHAPPAM, TOMATO CHUTNEY, TEA, COFFEE, MILK", "ICE CREAM, CHAPPTHI, BUTTER CHICKEN/CHILLY CHICKEN, PANEER BUTTER MASALA, RICE MBAR, PORIYAL, RASAM, BUTTERMILK, PICKLE, FRYMES", "SAMOSA ,TEA, COFFEE, MILK P& BREAD,BUTTER, JAM", "SALAD, WHEAT PARATHA,GREEN PEAS KURMA, RAVA KICHADI,COCONUT CHUTNEY, WHITE RICE, RASAM,BANANA, MILK"], 28 | "ai": "Showing what's in PF mess.", 29 | "slots": [450, 690, 990, 1170], 30 | "slotNames": ["breakfast", "lunch", "snacks", "dinner"] 31 | }, 32 | "mano": { 33 | "0": ["Bread,ButterJam, Chappathi,Karamani Kurma, Tea, Coffee, Milk.", "Chappathi,Aloo Mutter,Veg Biriyanl/Bahara Pulao, Onian Raitha, White Rice,Mysore Dal Fry,Frymes,Manga Pickle,Sweet-Kesari.", "Cake/Donut, Tea, Coffee.", "Poarl,Moong Dal Tadka,3lack Channa Cary,Non-Veg Gravy,White Rice,Frymes,Lemon Pickle, Milk(150ml), Green Salad, Banana."], 34 | "1": ["Bread,Butter Jam, Poha, Tea, Coffee,Milk.", "Tea.Coffearatha, Veg Chettinad,White Rice Dal Taduka,Veg Sabzi, Butter Milk,Mixed Pickle, Frymes.", "Bread, Jam,Bajjl/Aloo Bonda, Tea, Coffee.", "Chappathl white Peas Kurma,Veg Pulao,Dal Fry,White Rice Neg Manchurian,Non Veg Gravy,Butter MIlk,Mango Pickle Frymes,Mild150ml), Green Salad,Fresh Fruits."], 35 | "2": ["Bread,Rutter,Jam, Idly,Masala Omlette, Sambar Chutney,Tea, Coffee,Milk, Banana.", "Poori, Potato Masala,White Rice, Tomato Fry, Kadai Veg Sabzi,Butter Milk,Lemon Pickle,Sweet- Boondhi/Mysore Pak.", "Bread, Jam,Veg Puffs, Tea. Coffee", "Chappathi, Veg(Panner) Non-VeglChicken Masala/Chilly Chicken],White Rice,Tomato Dal, Butter milk ,Green Salad,Frymes,Mixed Pickle. Milk(150ml, Ice cream."], 36 | "3": ["Bread,Butter, Jam,Chappathi, White Peas Curry, Tea, Coffee, MIlk", "Chappathi,Rajma Curry,White Rice,Bagara Dal,Veg Dry Sabzi, Butter Milk Pickle, Frymes", "Bread, Jam, Bonda/Sweet Corn, Tea, Caffee.", "Chola Poori, Chola Masala,While Rice,Dal fry Nan Veg Gravy,Butter milk Lemon Pickle, Milkd150ml), Green Salad, Bannana."], 37 | "4": ["Bread, ButterJam, Chappathi,Alga Curry, Tea,Coffee, Milk", "Veechu Chapp.athi Veg Chettinad White Rice,Moong Dal fry Aloo Gobl Dry, Mango Pickle, Frymes,Bread Halwa/Sarkarai Pongal.", "Bread, JamCurd Vada/Mysore Bonda,Tea, Coffee. ", "Aloo Parata, Meal Maker Curry, White Rice,Mix Dal Fry,Vegetable Dry,Vegl French Fry),Non Veg(Egg Keema Masala),Green Salad, Frymes,Mixed Pickle,Milk(150ml), Banana-1."], 38 | "5": ["Bread, Butter Jam, Chappathi, uruma, Tea,Coffee ,Milk.", "Poori,Green Peas Masala, White Rice,Toor Dal VegiTadka,Bindl dobyaza,Butter Milk Lemon Pickle Frymes", "Pav Bhaji, Bread. Tea, Coffee", "Chappathi,Mix Veg Curry,Veg Noodles,Tomato Sauce,White Rice,Hara Toor Dal Fry,Nan-Veg Gravy, Milk150ml), Frymes, Mango Pickle, Green Salad,Banana-1"], 39 | "6": ["Tea,Coffee ,Milk. la Poori, Chola Masala, Tea,Coffee,Milk", "Chappathi,Veg (Panner), Non-Veg(Chicken Masala 1,White Rice,Moong Dal Fry, Butter Milk,Mixed Plckle, Frymes, Ice Cream.", "Bread, Jam,Pakoda/Kara Sev, Tea, Coffee.", "Diamond Chappathi ,Aloo Parval Masala, White Rice Chola Dal Tadka,Non Veg Gravy,Milk(150ml), Lemon Pickle, Frymes, Green Salad, Seasonal Fruit."], 40 | "ai": "Here's the menu of Mano mess.", 41 | "slotNames": ["breakfast", "lunch", "snacks", "dinner"] 42 | } 43 | } -------------------------------------------------------------------------------- /academia.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Sign In 22 | 23 | 24 | 87 | 186 | 187 | 188 | 189 | 190 | 191 |
      192 |
      193 |
      194 | 195 |
      196 |
      197 | 198 | 199 |
      200 |
      201 | 202 |
      203 |
      204 | 205 | 206 |
      207 | 212 |
      213 | 214 |
      215 |
      216 |
      217 | 240 | 241 | -------------------------------------------------------------------------------- /Apis/birthday.json: -------------------------------------------------------------------------------- 1 | { 2 | "january":{ 3 | "1st": ["yuri"], 4 | "2nd": [""], 5 | "3rd": [""], 6 | "4th": [""], 7 | "5th": [""], 8 | "6th": [""], 9 | "7th": [""], 10 | "8th": [""], 11 | "9th": [""], 12 | "10th": [""], 13 | "11th": [""], 14 | "12th": [""], 15 | "13th": [""], 16 | "14th": [""], 17 | "15th": [""], 18 | "16th": [""], 19 | "17th": [""], 20 | "18th": [""], 21 | "19th": [""], 22 | "20th": [""], 23 | "21st": [""], 24 | "22nd": [""], 25 | "23rd": [""], 26 | "24th": [""], 27 | "25th": [""], 28 | "26th": [""], 29 | "27th": [""], 30 | "28th": [""], 31 | "29th": [""], 32 | "30th": [""], 33 | "31th": [""] 34 | }, 35 | "febuary":{ 36 | "1st": [""], 37 | "2nd": [""], 38 | "3rd": [""], 39 | "4th": [""], 40 | "5th": [""], 41 | "6th": [""], 42 | "7th": [""], 43 | "8th": [""], 44 | "9th": [""], 45 | "10th": [""], 46 | "11th": [""], 47 | "12th": [""], 48 | "13th": [""], 49 | "14th": [""], 50 | "15th": [""], 51 | "16th": [""], 52 | "17th": [""], 53 | "18th": [""], 54 | "19th": [""], 55 | "20th": [""], 56 | "21st": [""], 57 | "22nd": [""], 58 | "23rd": [""], 59 | "24th": [""], 60 | "25th": [""], 61 | "26th": [""], 62 | "27th": [""], 63 | "28th": [""], 64 | "29th": [""], 65 | "30th": [""], 66 | "31th": [""] 67 | }, 68 | "march":{ 69 | "1st": [""], 70 | "2nd": [""], 71 | "3rd": [""], 72 | "4th": [""], 73 | "5th": [""], 74 | "6th": [""], 75 | "7th": [""], 76 | "8th": [""], 77 | "9th": [""], 78 | "10th": [""], 79 | "11th": [""], 80 | "12th": [""], 81 | "13th": [""], 82 | "14th": [""], 83 | "15th": [""], 84 | "16th": [""], 85 | "17th": [""], 86 | "18th": [""], 87 | "19th": [""], 88 | "20th": [""], 89 | "21st": [""], 90 | "22nd": [""], 91 | "23rd": [""], 92 | "24th": [""], 93 | "25th": [""], 94 | "26th": [""], 95 | "27th": [""], 96 | "28th": [""], 97 | "29th": [""], 98 | "30th": [""], 99 | "31th": [""] 100 | }, 101 | "april":{ 102 | "1st": [""], 103 | "2nd": [""], 104 | "3rd": [""], 105 | "4th": [""], 106 | "5th": [""], 107 | "6th": [""], 108 | "7th": [""], 109 | "8th": [""], 110 | "9th": [""], 111 | "10th": [""], 112 | "11th": [""], 113 | "12th": [""], 114 | "13th": [""], 115 | "14th": [""], 116 | "15th": [""], 117 | "16th": [""], 118 | "17th": [""], 119 | "18th": [""], 120 | "19th": [""], 121 | "20th": [""], 122 | "21st": [""], 123 | "22nd": [""], 124 | "23rd": [""], 125 | "24th": [""], 126 | "25th": [""], 127 | "26th": [""], 128 | "27th": [""], 129 | "28th": [""], 130 | "29th": [""], 131 | "30th": [""], 132 | "31th": [""] 133 | }, 134 | "may":{ 135 | "1st": [""], 136 | "2nd": [""], 137 | "3rd": [""], 138 | "4th": [""], 139 | "5th": [""], 140 | "6th": [""], 141 | "7th": [""], 142 | "8th": [""], 143 | "9th": [""], 144 | "10th": [""], 145 | "11th": [""], 146 | "12th": [""], 147 | "13th": [""], 148 | "14th": [""], 149 | "15th": [""], 150 | "16th": [""], 151 | "17th": [""], 152 | "18th": [""], 153 | "19th": [""], 154 | "20th": [""], 155 | "21st": [""], 156 | "22nd": [""], 157 | "23rd": [""], 158 | "24th": [""], 159 | "25th": [""], 160 | "26th": [""], 161 | "27th": [""], 162 | "28th": [""], 163 | "29th": [""], 164 | "30th": [""], 165 | "31th": [""] 166 | }, 167 | "june":{ 168 | "1st": [""], 169 | "2nd": [""], 170 | "3rd": [""], 171 | "4th": [""], 172 | "5th": [""], 173 | "6th": [""], 174 | "7th": [""], 175 | "8th": [""], 176 | "9th": [""], 177 | "10th": [""], 178 | "11th": [""], 179 | "12th": [""], 180 | "13th": [""], 181 | "14th": [""], 182 | "15th": [""], 183 | "16th": [""], 184 | "17th": [""], 185 | "18th": [""], 186 | "19th": [""], 187 | "20th": [""], 188 | "21st": [""], 189 | "22nd": [""], 190 | "23rd": [""], 191 | "24th": [""], 192 | "25th": [""], 193 | "26th": [""], 194 | "27th": [""], 195 | "28th": [""], 196 | "29th": [""], 197 | "30th": [""], 198 | "31th": [""] 199 | }, 200 | "23rd": ["", "mudit"], 201 | "24th": [""], 202 | "25th": [""], 203 | "26th": [""], 204 | "27th": [""], 205 | "28th": [""], 206 | "29th": [""], 207 | "30th": [""], 208 | "31th": [""] 209 | }, 210 | "august":{ 211 | "1st": [""], 212 | "2nd": [""], 213 | "3rd": [""], 214 | "4th": [""], 215 | "5th": [""], 216 | "6th": [""], 217 | "7th": [""], 218 | "8th": [""], 219 | "9th": [""], 220 | "10th": [""], 221 | "11th": [""], 222 | "12th": [""], 223 | "13th": [""], 224 | "14th": [""], 225 | "15th": [""], 226 | "16th": [""], 227 | "17th": [""], 228 | "18th": [""], 229 | "19th": [""], 230 | "20th": [""], 231 | "21st": [""], 232 | "22nd": [""], 233 | "23rd": [""], 234 | "24th": [""], 235 | "25th": [""], 236 | "26th": [""], 237 | "27th": [""], 238 | "28th": [""], 239 | "29th": [""], 240 | "30th": [""], 241 | "31th": [""] 242 | }, 243 | "september":{ 244 | "1st": [""], 245 | "2nd": [""], 246 | "3rd": [""], 247 | "4th": [""], 248 | "5th": [""], 249 | "6th": [""], 250 | "7th": [""], 251 | "8th": [""], 252 | "9th": [""], 253 | "10th": [""], 254 | "11th": [""], 255 | "12th": [""], 256 | "13th": [""], 257 | "14th": [""], 258 | "15th": [""], 259 | "16th": [""], 260 | "17th": [""], 261 | "18th": [""], 262 | "19th": [""], 263 | "20th": [""], 264 | "21st": [""], 265 | "22nd": [""], 266 | "23rd": [""], 267 | "24th": [""], 268 | "25th": [""], 269 | "26th": [""], 270 | "27th": [""], 271 | "28th": [""], 272 | "29th": [""], 273 | "30th": [""], 274 | "31th": [""] 275 | }, 276 | "october":{ 277 | "1st": [""], 278 | "2nd": [""], 279 | "3rd": [""], 280 | "4th": [""], 281 | "5th": [""], 282 | "6th": [""], 283 | "7th": [""], 284 | "8th": [""], 285 | "9th": [""], 286 | "10th": [""], 287 | "11th": [""], 288 | "12th": [""], 289 | "13th": [""], 290 | "14th": [""], 291 | "15th": [""], 292 | "16th": [""], 293 | "17th": [""], 294 | "18th": [""], 295 | "19th": [""], 296 | "20th": [""], 297 | "21st": [""], 298 | "22nd": [""], 299 | "23rd": [""], 300 | "24th": [""], 301 | "25th": [""], 302 | "26th": [""], 303 | "27th": [""], 304 | "28th": [""], 305 | "29th": [""], 306 | "30th": [""], 307 | "31th": [""] 308 | }, 309 | "november":{ 310 | "1st": [""], 311 | "2nd": [""], 312 | "3rd": [""], 313 | "4th": [""], 314 | "5th": [""], 315 | "6th": [""], 316 | "7th": [""], 317 | "8th": [""], 318 | "9th": [""], 319 | "10th": [""], 320 | "11th": [""], 321 | "12th": [""], 322 | "13th": [""], 323 | "14th": [""], 324 | "15th": [""], 325 | "16th": [""], 326 | "17th": [""], 327 | "18th": [""], 328 | "19th": [""], 329 | "20th": [""], 330 | "21st": [""], 331 | "22nd": [""], 332 | "23rd": [""], 333 | "24th": [""], 334 | "25th": [""], 335 | "26th": [""], 336 | "27th": [""], 337 | "28th": [""], 338 | "29th": [""], 339 | "30th": [""], 340 | "31th": [""] 341 | }, 342 | "december":{ 343 | "1st": [""], 344 | "2nd": [""], 345 | "3rd": [""], 346 | "4th": [""], 347 | "5th": [""], 348 | "6th": [""], 349 | "7th": [""], 350 | "8th": [""], 351 | "9th": [""], 352 | "10th": [""], 353 | "11th": [""], 354 | "12th": [""], 355 | "13th": [""], 356 | "14th": [""], 357 | "15th": [""], 358 | "16th": [""], 359 | "17th": [""], 360 | "18th": [""], 361 | "19th": [""], 362 | "20th": [""], 363 | "21st": [""], 364 | "22nd": [""], 365 | "23rd": [""], 366 | "24th": [""], 367 | "25th": [""], 368 | "26th": [""], 369 | "27th": [""], 370 | "28th": [""], 371 | "29th": [""], 372 | "30th": [""], 373 | "31th": [""] 374 | } 375 | } -------------------------------------------------------------------------------- /birthdayFormat.json: -------------------------------------------------------------------------------- 1 | { 2 | "january": { 3 | "1st": ["yuri"], 4 | "2nd": [""], 5 | "3rd": [""], 6 | "4th": [""], 7 | "5th": [""], 8 | "6th": [""], 9 | "7th": [""], 10 | "8th": [""], 11 | "9th": [""], 12 | "10th": [""], 13 | "11th": [""], 14 | "12th": [""], 15 | "13th": [""], 16 | "14th": [""], 17 | "15th": [""], 18 | "16th": [""], 19 | "17th": [""], 20 | "18th": [""], 21 | "19th": [""], 22 | "20th": [""], 23 | "21st": [""], 24 | "22nd": [""], 25 | "23rd": [""], 26 | "24th": [""], 27 | "25th": [""], 28 | "26th": [""], 29 | "27th": [""], 30 | "28th": [""], 31 | "29th": [""], 32 | "30th": [""], 33 | "31th": [""] 34 | }, 35 | "febuary": { 36 | "1st": [""], 37 | "2nd": [""], 38 | "3rd": [""], 39 | "4th": [""], 40 | "5th": [""], 41 | "6th": [""], 42 | "7th": [""], 43 | "8th": [""], 44 | "9th": [""], 45 | "10th": [""], 46 | "11th": [""], 47 | "12th": [""], 48 | "13th": [""], 49 | "14th": [""], 50 | "15th": [""], 51 | "16th": [""], 52 | "17th": [""], 53 | "18th": [""], 54 | "19th": [""], 55 | "20th": [""], 56 | "21st": [""], 57 | "22nd": [""], 58 | "23rd": [""], 59 | "24th": [""], 60 | "25th": [""], 61 | "26th": [""], 62 | "27th": [""], 63 | "28th": [""], 64 | "29th": [""], 65 | "30th": [""], 66 | "31th": [""] 67 | }, 68 | "march": { 69 | "1st": [""], 70 | "2nd": [""], 71 | "3rd": [""], 72 | "4th": [""], 73 | "5th": [""], 74 | "6th": [""], 75 | "7th": [""], 76 | "8th": [""], 77 | "9th": [""], 78 | "10th": [""], 79 | "11th": [""], 80 | "12th": [""], 81 | "13th": [""], 82 | "14th": [""], 83 | "15th": [""], 84 | "16th": [""], 85 | "17th": [""], 86 | "18th": [""], 87 | "19th": [""], 88 | "20th": [""], 89 | "21st": [""], 90 | "22nd": [""], 91 | "23rd": [""], 92 | "24th": [""], 93 | "25th": [""], 94 | "26th": [""], 95 | "27th": [""], 96 | "28th": [""], 97 | "29th": [""], 98 | "30th": [""], 99 | "31th": [""] 100 | }, 101 | "april": { 102 | "1st": [""], 103 | "2nd": [""], 104 | "3rd": [""], 105 | "4th": [""], 106 | "5th": [""], 107 | "6th": [""], 108 | "7th": [""], 109 | "8th": [""], 110 | "9th": [""], 111 | "10th": [""], 112 | "11th": [""], 113 | "12th": [""], 114 | "13th": [""], 115 | "14th": [""], 116 | "15th": [""], 117 | "16th": [""], 118 | "17th": [""], 119 | "18th": [""], 120 | "19th": [""], 121 | "20th": [""], 122 | "21st": [""], 123 | "22nd": [""], 124 | "23rd": [""], 125 | "24th": [""], 126 | "25th": [""], 127 | "26th": [""], 128 | "27th": [""], 129 | "28th": [""], 130 | "29th": [""], 131 | "30th": [""], 132 | "31th": [""] 133 | }, 134 | "may": { 135 | "1st": [""], 136 | "2nd": [""], 137 | "3rd": [""], 138 | "4th": [""], 139 | "5th": [""], 140 | "6th": [""], 141 | "7th": [""], 142 | "8th": [""], 143 | "9th": [""], 144 | "10th": [""], 145 | "11th": [""], 146 | "12th": [""], 147 | "13th": [""], 148 | "14th": [""], 149 | "15th": [""], 150 | "16th": [""], 151 | "17th": [""], 152 | "18th": [""], 153 | "19th": [""], 154 | "20th": [""], 155 | "21st": [""], 156 | "22nd": [""], 157 | "23rd": [""], 158 | "24th": [""], 159 | "25th": [""], 160 | "26th": [""], 161 | "27th": [""], 162 | "28th": [""], 163 | "29th": [""], 164 | "30th": [""], 165 | "31th": [""] 166 | }, 167 | "june": { 168 | "1st": [""], 169 | "2nd": [""], 170 | "3rd": [""], 171 | "4th": [""], 172 | "5th": [""], 173 | "6th": [""], 174 | "7th": [""], 175 | "8th": [""], 176 | "9th": [""], 177 | "10th": [""], 178 | "11th": [""], 179 | "12th": [""], 180 | "13th": [""], 181 | "14th": [""], 182 | "15th": [""], 183 | "16th": [""], 184 | "17th": [""], 185 | "18th": [""], 186 | "19th": [""], 187 | "20th": [""], 188 | "21st": [""], 189 | "22nd": [""], 190 | "23rd": [""], 191 | "24th": [""], 192 | "25th": [""], 193 | "26th": [""], 194 | "27th": [""], 195 | "28th": [""], 196 | "29th": [""], 197 | "30th": [""], 198 | "31th": [""] 199 | }, 200 | "july": { 201 | "1st": [""], 202 | "2nd": [""], 203 | "3rd": [""], 204 | "4th": [""], 205 | "5th": [""], 206 | "6th": [""], 207 | "7th": [""], 208 | "8th": [""], 209 | "9th": [""], 210 | "10th": [""], 211 | "11th": [""], 212 | "12th": [""], 213 | "13th": [""], 214 | "14th": [""], 215 | "15th": [""], 216 | "16th": [""], 217 | "17th": [""], 218 | "18th": [""], 219 | "19th": [""], 220 | "20th": [""], 221 | "21st": [""], 222 | "22nd": [""], 223 | "23rd": [""], 224 | "24th": [""], 225 | "25th": [""], 226 | "26th": [""], 227 | "27th": [""], 228 | "28th": [""], 229 | "29th": [""], 230 | "30th": [""], 231 | "31th": [""] 232 | }, 233 | "august": { 234 | "1st": [""], 235 | "2nd": [""], 236 | "3rd": [""], 237 | "4th": [""], 238 | "5th": [""], 239 | "6th": [""], 240 | "7th": [""], 241 | "8th": [""], 242 | "9th": [""], 243 | "10th": [""], 244 | "11th": [""], 245 | "12th": [""], 246 | "13th": [""], 247 | "14th": [""], 248 | "15th": [""], 249 | "16th": [""], 250 | "17th": [""], 251 | "18th": [""], 252 | "19th": [""], 253 | "20th": [""], 254 | "21st": [""], 255 | "22nd": [""], 256 | "23rd": [""], 257 | "24th": [""], 258 | "25th": [""], 259 | "26th": [""], 260 | "27th": [""], 261 | "28th": [""], 262 | "29th": [""], 263 | "30th": [""], 264 | "31th": [""] 265 | }, 266 | "september": { 267 | "1st": [""], 268 | "2nd": [""], 269 | "3rd": [""], 270 | "4th": [""], 271 | "5th": [""], 272 | "6th": [""], 273 | "7th": [""], 274 | "8th": [""], 275 | "9th": [""], 276 | "10th": [""], 277 | "11th": [""], 278 | "12th": [""], 279 | "13th": [""], 280 | "14th": [""], 281 | "15th": [""], 282 | "16th": [""], 283 | "17th": [""], 284 | "18th": [""], 285 | "19th": [""], 286 | "20th": [""], 287 | "21st": [""], 288 | "22nd": [""], 289 | "23rd": [""], 290 | "24th": [""], 291 | "25th": [""], 292 | "26th": [""], 293 | "27th": [""], 294 | "28th": [""], 295 | "29th": [""], 296 | "30th": [""], 297 | "31th": [""] 298 | }, 299 | "october": { 300 | "1st": [""], 301 | "2nd": [""], 302 | "3rd": [""], 303 | "4th": [""], 304 | "5th": [""], 305 | "6th": [""], 306 | "7th": [""], 307 | "8th": [""], 308 | "9th": [""], 309 | "10th": [""], 310 | "11th": [""], 311 | "12th": [""], 312 | "13th": [""], 313 | "14th": [""], 314 | "15th": [""], 315 | "16th": [""], 316 | "17th": [""], 317 | "18th": [""], 318 | "19th": [""], 319 | "20th": [""], 320 | "21st": [""], 321 | "22nd": [""], 322 | "23rd": [""], 323 | "24th": [""], 324 | "25th": [""], 325 | "26th": [""], 326 | "27th": [""], 327 | "28th": [""], 328 | "29th": [""], 329 | "30th": [""], 330 | "31th": [""] 331 | }, 332 | "november": { 333 | "1st": [""], 334 | "2nd": [""], 335 | "3rd": [""], 336 | "4th": [""], 337 | "5th": [""], 338 | "6th": [""], 339 | "7th": [""], 340 | "8th": [""], 341 | "9th": [""], 342 | "10th": [""], 343 | "11th": [""], 344 | "12th": [""], 345 | "13th": [""], 346 | "14th": [""], 347 | "15th": [""], 348 | "16th": [""], 349 | "17th": [""], 350 | "18th": [""], 351 | "19th": [""], 352 | "20th": [""], 353 | "21st": [""], 354 | "22nd": [""], 355 | "23rd": [""], 356 | "24th": [""], 357 | "25th": [""], 358 | "26th": [""], 359 | "27th": [""], 360 | "28th": [""], 361 | "29th": [""], 362 | "30th": [""], 363 | "31th": [""] 364 | }, 365 | "december": { 366 | "1st": [""], 367 | "2nd": [""], 368 | "3rd": [""], 369 | "4th": [""], 370 | "5th": [""], 371 | "6th": [""], 372 | "7th": [""], 373 | "8th": [""], 374 | "9th": [""], 375 | "10th": [""], 376 | "11th": [""], 377 | "12th": [""], 378 | "13th": [""], 379 | "14th": [""], 380 | "15th": [""], 381 | "16th": [""], 382 | "17th": [""], 383 | "18th": [""], 384 | "19th": [""], 385 | "20th": [""], 386 | "21st": [""], 387 | "22nd": [""], 388 | "23rd": [""], 389 | "24th": [""], 390 | "25th": [""], 391 | "26th": [""], 392 | "27th": [""], 393 | "28th": [""], 394 | "29th": [""], 395 | "30th": [""], 396 | "31th": [""] 397 | } 398 | } -------------------------------------------------------------------------------- /birthday.json: -------------------------------------------------------------------------------- 1 | { 2 | "january": { 3 | "1st": [""], 4 | "2nd": [""], 5 | "3rd": [""], 6 | "4th": [""], 7 | "5th": [""], 8 | "6th": [""], 9 | "7th": [""], 10 | "8th": [""], 11 | "9th": [""], 12 | "10th": ["", "shubhankar srm"], 13 | "11th": [""], 14 | "12th": [""], 15 | "13th": [""], 16 | "14th": [""], 17 | "15th": [""], 18 | "16th": [""], 19 | "17th": [""], 20 | "18th": [""], 21 | "19th": [""], 22 | "20th": [""], 23 | "21st": [""], 24 | "22nd": [""], 25 | "23rd": [""], 26 | "24th": [""], 27 | "25th": [""], 28 | "26th": [""], 29 | "27th": [""], 30 | "28th": [""], 31 | "29th": [""], 32 | "30th": [""], 33 | "31th": [""] 34 | }, 35 | "febuary": { 36 | "1st": [""], 37 | "2nd": [""], 38 | "3rd": [""], 39 | "4th": [""], 40 | "5th": [""], 41 | "6th": [""], 42 | "7th": [""], 43 | "8th": [""], 44 | "9th": [""], 45 | "10th": [""], 46 | "11th": [""], 47 | "12th": [""], 48 | "13th": [""], 49 | "14th": [""], 50 | "15th": [""], 51 | "16th": [""], 52 | "17th": [""], 53 | "18th": [""], 54 | "19th": [""], 55 | "20th": [""], 56 | "21st": [""], 57 | "22nd": [""], 58 | "23rd": [""], 59 | "24th": [""], 60 | "25th": [""], 61 | "26th": [""], 62 | "27th": [""], 63 | "28th": [""], 64 | "29th": [""], 65 | "30th": [""], 66 | "31th": [""] 67 | }, 68 | "march": { 69 | "1st": [""], 70 | "2nd": [""], 71 | "3rd": [""], 72 | "4th": [""], 73 | "5th": [""], 74 | "6th": [""], 75 | "7th": [""], 76 | "8th": [""], 77 | "9th": [""], 78 | "10th": [""], 79 | "11th": [""], 80 | "12th": [""], 81 | "13th": [""], 82 | "14th": [""], 83 | "15th": [""], 84 | "16th": [""], 85 | "17th": [""], 86 | "18th": [""], 87 | "19th": [""], 88 | "20th": [""], 89 | "21st": [""], 90 | "22nd": [""], 91 | "23rd": [""], 92 | "24th": [""], 93 | "25th": [""], 94 | "26th": [""], 95 | "27th": [""], 96 | "28th": [""], 97 | "29th": [""], 98 | "30th": [""], 99 | "31th": [""] 100 | }, 101 | "april": { 102 | "1st": [""], 103 | "2nd": [""], 104 | "3rd": [""], 105 | "4th": [""], 106 | "5th": [""], 107 | "6th": [""], 108 | "7th": [""], 109 | "8th": [""], 110 | "9th": [""], 111 | "10th": [""], 112 | "11th": [""], 113 | "12th": [""], 114 | "13th": [""], 115 | "14th": [""], 116 | "15th": [""], 117 | "16th": [""], 118 | "17th": [""], 119 | "18th": [""], 120 | "19th": [""], 121 | "20th": [""], 122 | "21st": [""], 123 | "22nd": [""], 124 | "23rd": [""], 125 | "24th": [""], 126 | "25th": [""], 127 | "26th": [""], 128 | "27th": [""], 129 | "28th": [""], 130 | "29th": [""], 131 | "30th": [""], 132 | "31th": [""] 133 | }, 134 | "may": { 135 | "1st": [""], 136 | "2nd": [""], 137 | "3rd": [""], 138 | "4th": [""], 139 | "5th": [""], 140 | "6th": [""], 141 | "7th": [""], 142 | "8th": [""], 143 | "9th": [""], 144 | "10th": [""], 145 | "11th": [""], 146 | "12th": [""], 147 | "13th": [""], 148 | "14th": [""], 149 | "15th": [""], 150 | "16th": [""], 151 | "17th": [""], 152 | "18th": [""], 153 | "19th": [""], 154 | "20th": [""], 155 | "21st": [""], 156 | "22nd": [""], 157 | "23rd": [""], 158 | "24th": [""], 159 | "25th": [""], 160 | "26th": [""], 161 | "27th": [""], 162 | "28th": [""], 163 | "29th": [""], 164 | "30th": [""], 165 | "31th": [""] 166 | }, 167 | "june": { 168 | "1st": [""], 169 | "2nd": [""], 170 | "3rd": [""], 171 | "4th": [""], 172 | "5th": [""], 173 | "6th": [""], 174 | "7th": [""], 175 | "8th": [""], 176 | "9th": [""], 177 | "10th": [""], 178 | "11th": [""], 179 | "12th": [""], 180 | "13th": [""], 181 | "14th": [""], 182 | "15th": [""], 183 | "16th": [""], 184 | "17th": [""], 185 | "18th": [""], 186 | "19th": [""], 187 | "20th": [""], 188 | "21st": [""], 189 | "22nd": [""], 190 | "23rd": [""], 191 | "24th": [""], 192 | "25th": [""], 193 | "26th": [""], 194 | "27th": ["", "naman thane"], 195 | "28th": [""], 196 | "29th": [""], 197 | "30th": [""], 198 | "31th": [""] 199 | }, 200 | "july": { 201 | "1st": [""], 202 | "2nd": [""], 203 | "3rd": [""], 204 | "4th": [""], 205 | "5th": [""], 206 | "6th": ["", "apoorv"], 207 | "7th": [""], 208 | "8th": [""], 209 | "9th": [""], 210 | "10th": [""], 211 | "11th": [""], 212 | "12th": [""], 213 | "13th": [""], 214 | "14th": [""], 215 | "15th": [""], 216 | "16th": [""], 217 | "17th": [""], 218 | "18th": [""], 219 | "19th": [""], 220 | "20th": [""], 221 | "21st": [""], 222 | "22nd": [""], 223 | "23rd": ["", "mudit"], 224 | "24th": [""], 225 | "25th": [""], 226 | "26th": [""], 227 | "27th": [""], 228 | "28th": [""], 229 | "29th": [""], 230 | "30th": [""], 231 | "31th": [""] 232 | }, 233 | "august": { 234 | "1st": [""], 235 | "2nd": [""], 236 | "3rd": [""], 237 | "4th": [""], 238 | "5th": ["", "shaury srm"], 239 | "6th": [""], 240 | "7th": [""], 241 | "8th": [""], 242 | "9th": [""], 243 | "10th": [""], 244 | "11th": [""], 245 | "12th": [""], 246 | "13th": ["", "rahul"], 247 | "14th": [""], 248 | "15th": [""], 249 | "16th": [""], 250 | "17th": [""], 251 | "18th": [""], 252 | "19th": [""], 253 | "20th": [""], 254 | "21st": [""], 255 | "22nd": ["", "rishi"], 256 | "23rd": [""], 257 | "24th": ["", "ishu"], 258 | "25th": ["", "akshay"], 259 | "26th": [""], 260 | "27th": [""], 261 | "28th": [""], 262 | "29th": [""], 263 | "30th": ["", "aditya pari"], 264 | "31th": [""] 265 | }, 266 | "september": { 267 | "1st": [""], 268 | "2nd": [""], 269 | "3rd": [""], 270 | "4th": ["", "abhishek saji"], 271 | "5th": [""], 272 | "6th": [""], 273 | "7th": [""], 274 | "8th": [""], 275 | "9th": [""], 276 | "10th": [""], 277 | "11th": [""], 278 | "12th": [""], 279 | "13th": [""], 280 | "14th": [""], 281 | "15th": [""], 282 | "16th": [""], 283 | "17th": [""], 284 | "18th": [""], 285 | "19th": [""], 286 | "20th": [""], 287 | "21st": [""], 288 | "22nd": [""], 289 | "23rd": [""], 290 | "24th": [""], 291 | "25th": [""], 292 | "26th": [""], 293 | "27th": [""], 294 | "28th": [""], 295 | "29th": [""], 296 | "30th": [""], 297 | "31th": [""] 298 | }, 299 | "october": { 300 | "1st": [""], 301 | "2nd": [""], 302 | "3rd": [""], 303 | "4th": [""], 304 | "5th": [""], 305 | "6th": [""], 306 | "7th": [""], 307 | "8th": [""], 308 | "9th": [""], 309 | "10th": [""], 310 | "11th": [""], 311 | "12th": [""], 312 | "13th": [""], 313 | "14th": [""], 314 | "15th": [""], 315 | "16th": [""], 316 | "17th": [""], 317 | "18th": [""], 318 | "19th": [""], 319 | "20th": [""], 320 | "21st": [""], 321 | "22nd": [""], 322 | "23rd": [""], 323 | "24th": [""], 324 | "25th": [""], 325 | "26th": [""], 326 | "27th": [""], 327 | "28th": [""], 328 | "29th": [""], 329 | "30th": [""], 330 | "31th": [""] 331 | }, 332 | "november": { 333 | "1st": [""], 334 | "2nd": [""], 335 | "3rd": [""], 336 | "4th": [""], 337 | "5th": [""], 338 | "6th": [""], 339 | "7th": ["", "betu didi"], 340 | "8th": [""], 341 | "9th": [""], 342 | "10th": [""], 343 | "11th": ["", "samiksha didi"], 344 | "12th": [""], 345 | "13th": [""], 346 | "14th": [""], 347 | "15th": [""], 348 | "16th": [""], 349 | "17th": [""], 350 | "18th": [""], 351 | "19th": [""], 352 | "20th": [""], 353 | "21st": [""], 354 | "22nd": [""], 355 | "23rd": [""], 356 | "24th": [""], 357 | "25th": [""], 358 | "26th": [""], 359 | "27th": [""], 360 | "28th": [""], 361 | "29th": [""], 362 | "30th": [""], 363 | "31th": [""] 364 | }, 365 | "december": { 366 | "1st": [""], 367 | "2nd": [""], 368 | "3rd": [""], 369 | "4th": [""], 370 | "5th": [""], 371 | "6th": ["", "shikhar srm"], 372 | "7th": [""], 373 | "8th": [""], 374 | "9th": [""], 375 | "10th": [""], 376 | "11th": [""], 377 | "12th": [""], 378 | "13th": [""], 379 | "14th": [""], 380 | "15th": [""], 381 | "16th": [""], 382 | "17th": [""], 383 | "18th": [""], 384 | "19th": [""], 385 | "20th": [""], 386 | "21st": [""], 387 | "22nd": [""], 388 | "23rd": [""], 389 | "24th": [""], 390 | "25th": [""], 391 | "26th": [""], 392 | "27th": [""], 393 | "28th": [""], 394 | "29th": [""], 395 | "30th": [""], 396 | "31th": [""] 397 | } 398 | } -------------------------------------------------------------------------------- /simplehtmldom_1_9/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | All notable changes to this project will be documented in this file. 3 | 4 | The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). 5 | 6 | ## [1.9] - 2019-05-30 7 | ### Added 8 | - Added unit test for bug reports 9 | - Added test for bug [#153](https://sourceforge.net/p/simplehtmldom/bugs/153/) 10 | - Added test for bug [#163](https://sourceforge.net/p/simplehtmldom/bugs/163/) 11 | - Added test for bug [#166](https://sourceforge.net/p/simplehtmldom/bugs/166/) 12 | - Added test for bug [#169](https://sourceforge.net/p/simplehtmldom/bugs/169/) 13 | - Added unit test for character sets UTF-8, CP1251 and CP1252 (#142) 14 | - Added support for meta charset to parse_charset 15 | - Added detection for CP1251 to parse_charset, using iconv 16 | - Added LICENSE file (MIT) to the project root 17 | - Added functions to `simple_html_dom_node` 18 | - `remove`: Removes the current node recursively from the DOM tree 19 | - `removeChild`: Removes a child node recursively from the DOM tree 20 | - `hasClass`: Checks if the current node has the specified class name 21 | - `addClass`: Adds one or more classes to the current node 22 | - `removeClass`: Removes one or more classes from the current node 23 | - `save`: Saves the current node to disk 24 | ### Changed 25 | - Changed manual from custom implementation to MkDocs (https://www.mkdocs.org/) 26 | ### Fixed 27 | - Fixed warning when trying to clear() the DOM on a null nodes list (#153) 28 | - Fixed missing whitespace when returning plaintext (#163) 29 | - Fixed broken detection of duplicate attributes (#166) 30 | - Fixed broken detection of CP1252 (ISO-8859-1) documents (#142) 31 | - Fixed error using next-sibling combinator ('E + F') on last child 32 | - Fixed selector parsing for attribute selectors ending on "s" or "i" (#169) 33 | 34 | ## [1.8.1] - 2019-01-13 35 | ### Fixed 36 | - Fixed various bugs related to parsing classes and ids 37 | 38 | ## [1.8] - 2019-01-13 39 | ### Added 40 | - Added documentation for `simple_html_dom_node::find` 41 | - Added documentation for `simple_html_dom_node::parse_selector` 42 | - Added documentation for `simple_html_dom_node::seek` 43 | - Added documentation for `simple_html_dom_node::match` 44 | - Added unit tests for bug reports 45 | - Added test for bug [#62](https://sourceforge.net/p/simplehtmldom/bugs/62/) 46 | - Added test for bug [#79](https://sourceforge.net/p/simplehtmldom/bugs/79/) 47 | - Added test for bug [#144](https://sourceforge.net/p/simplehtmldom/bugs/144/) 48 | - Added unit tests for CSS selectors 49 | - Added ability to define constants before simple_html_dom does 50 | - 'DEFAULT_TARGET_CHARSET' 51 | - 'DEFAULT_BR_TEXT' 52 | - 'DEFAULT_SPAN_TEXT' 53 | - 'MAX_FILE_SIZE' 54 | - Added support for CSS combinators 55 | - Added support for Child Combinator (`>`) 56 | - Added support for Next Sibling Combinator (`+`) 57 | - Added support for Subsequent Sibling Combinator (`~`) 58 | - Added support for multiclass selectors (`.class.class.class`) 59 | - Added support for multiattribute selectors (`[attr1][attr2][attribute3]`) 60 | - Added support for attribute selectors 61 | - Added support for pipe selectors (`|=`) 62 | - Added support for tilde selectors (`~=`) 63 | - Added support for case sensitivity selectors (`i` and `s`) 64 | - Added unit tests for PHP compatibility to PHP 5.6+ 65 | - Added coding standard using PHP_CodeSniffer 66 | ### Changed 67 | - Removed automatic filtering of 'tbody' selectors (#79) 68 | > Remove 'tbody' from all selectors to maintain the previous state! 69 | - Coding standard using PHP_CodeSniffer 70 | ### Fixed 71 | - Fixed broken CSS selector attributes with value "0" (#62) 72 | - Fixed broken simple_html_dom::load_file 73 | - Fixed forward slashes in CSS selector breaks value matching using '*=' (#144) 74 | - Fixed Universal Selectors 75 | 76 | ## [1.7] - 2018-12-10 77 | ### Added 78 | - Added code documentation to improve readability 79 | - Added unit tests for `simple_html_dom::$self_closing_tags` 80 | - Added unit tests for `simple_html_dom::$optional_closing_tags` 81 | - Added unit tests for bug reports 82 | - Added test for bug [#56](https://sourceforge.net/p/simplehtmldom/bugs/56/) 83 | - Added test for bug [#97](https://sourceforge.net/p/simplehtmldom/bugs/97/) 84 | - Added test for bug [#116](https://sourceforge.net/p/simplehtmldom/bugs/116/) 85 | - Added test for bug [#121](https://sourceforge.net/p/simplehtmldom/bugs/127/) 86 | - Added test for bug [#127](https://sourceforge.net/p/simplehtmldom/bugs/127/) 87 | - Added test for bug [#154](https://sourceforge.net/p/simplehtmldom/bugs/154/) 88 | - Added test for bug [#160](https://sourceforge.net/p/simplehtmldom/bugs/160/) 89 | - Added unit tests for memory management of the parser 90 | - Added bit flags to `simple_html_dom::load()` 91 | - Added bit flag `HDOM_SMARTY_AS_TEXT` to optionally filter Smarty scripts (#154)\ 92 | **Note**: Smarty scripts are no longer filtered by default!\ 93 | - Added build script to automate releases 94 | - Added support for attributes without whitespace to separate them 95 | ### Changed 96 | - Improved documentation and readability for `$self_closing_tags` 97 | - Improved documentation and readability for `$block_tags` 98 | - Improved documentation and readability for `$optional_closing_tags` 99 | - Updated list of `simple_html_dom::$self_closing_tags` 100 | - Removed 'spacer' (obsolete) 101 | - Added 'area' 102 | - Added 'col' 103 | - Added 'meta' 104 | - Added 'param' 105 | - Added 'source' 106 | - Added 'track' 107 | - Added 'wbr' 108 | - Updated list of `simple_html_dom::$optional_closing_tags` 109 | - Removed "nobr" (obsolete) 110 | - Added 'th' as closable element to 'td' 111 | - Added 'td' as closable element to 'th' 112 | - Added 'optgroup' with 'optgroup' and 'option' as closable elements 113 | - Added 'optgroup' as closable element to 'option' 114 | - Added 'rp' with 'rp' and 'rt' as closable elements 115 | - Added 'rt' with 'rt' and 'rp' as closable elements 116 | - Clarified meaning of `simple_html_dom->parent` 117 | - Changed default `$offset` for `file_get_html()` from -1 to 0 (#161) 118 | - Changed `simple_html_dom::load()` to remove script tags before replacing newline characters 119 | - `simple_html_dom_node::text()` no longer adds whitespace to top level span elements (only to sub-elements) 120 | - `simple_html_dom_node::text()` adds blank lines between paragraphs 121 | - Normalized line endings in the repository to LF via `.gitattributes` 122 | - Improved performance of `simple_html_dom::parse_charset()` by approximately 25% 123 | - Improved performance of `simple_html_dom::parse()` by approximately 10% 124 | ### Deprecated 125 | - `str_get_html()` is deprecated and should be replaced by `new simple_html_dom()` 126 | ### Removed 127 | - Removed protected function `simple_html_dom::copy_until_char_escaped()` 128 | ### Fixed 129 | - Fixed compatibility issues with PHP 7.3 130 | - Fixed typo (#147) 131 | - Fixed handling of incorrectly escaped text (#160) 132 | - Restore functionality of `$maxLen` in `file_get_html()` 133 | - Fixed load_file breaks if an error ocurred in another script 134 | 135 | ## [1.6] - 2014-05-28 136 | ### Added 137 | - Added some ability to insert and create nodes 138 | - Add ability to search the "noise" array 139 | 140 | ## [1.5] - 2012-09-10 141 | ### Added 142 | - Added flag: LOCK_EX while calling "file_put_contents()" 143 | - Added support for detecting the source html character set. This is used to convert characters when plaintext is requested. 144 | - Other little fixes and features, too numerous to categorize 145 | ### Changed 146 | - Error of "file_get_contents()" will be thrown as an exception 147 | ### Fixed 148 | - Fixed the typo of "token_blank_t" 149 | - Memory leak fixed 150 | 151 | ## [1.11] - 2008-12-14 152 | ### Added 153 | - Supports xpath generated from Firebug 154 | - New method "dump" of "simple_html_dom_node" 155 | - New attribute "xmltext" of "simple_html_dom_node" 156 | ### Changed 157 | - Remove preg_quote on selector match function: `[attribute*=value]` 158 | - Element "Comment" will treat as children 159 | ### Fixed 160 | - Fixed the problem with `
      `
      161 | - Fixed bug #2207477 (does not load some pages properly)
      162 | - Fixed bug #2315853 (Error with character after < sign)
      163 | 
      164 | ## [1.10] - 2008-10-25
      165 | ### Changed
      166 | - Negative indexes supports of "find" method, thanks for Vadim Voituk
      167 | - Constructor with automatically load contents either text or file/url, thanks for Antcs
      168 | - Fully supports wildcard in selectors
      169 | ### Fixed
      170 | - Fixed bug of confusing by the < symbol inside the text
      171 | - Fixed bug of dash in selectors
      172 | - Fixed bug of ``
      173 | - Fixed bug #2155883 (Nested List Parses Incorrectly)
      174 | - Fixed bug #2155113 (error with unclosed html tags)
      175 | 
      176 | ## [1.00] - 2008-09-05
      177 | ### Added
      178 | - New method "getAllAttributes" of "simple_html_dom_node"
      179 | - Supports full javascript string in selector: `$e->find("a[onclick=alert('hello')]")`
      180 | ### Changed
      181 | - Changed selector "*=" to case-insentive
      182 | ### Fixed
      183 | - Fixed the bug of selector in some critical conditions
      184 | - Fixed the bug of striping php tags
      185 | - Fixed the bug of remove_noise()
      186 | - Fixed the bug of noise in attributes
      187 | 
      188 | ## [0.99] - 2008-08-03
      189 | ### Changed
      190 | - Performance tuning (boost 10%)
      191 | - Memory requirement reduced by 25%
      192 | - Changed function name from "file_get_dom()" to "file_get_html()"
      193 | - Changed function name from "str_get_dom()" to "str_get_html()"
      194 | ### Fixed
      195 | - Fixed bug #2011286 (Error with unclosed html tags)
      196 | - Fixed bug #2012551 (Error parsing divs)
      197 | - Fixed bug #2020924 (Error for missed tag)
      198 | - Fixed bug (problem with `` tag's innertext)
      199 | 
      200 | ## [0.98] - 2008-06-24
      201 | ### Added
      202 | - Supports "multiple class" selector feature: `
      ` 203 | - New "callback function" feature 204 | - New "multiple selectors" feature: $dom->find('p,a,b') 205 | - New examples 206 | - Supports extract contents from HTML features: $dom->plaintext 207 | ### Changed 208 | - Performance tuning (boost 20%) 209 | - Changed simple_html_dom_node method name from "text()" to "makeup()" 210 | ### Fixed 211 | - Fixed the bug of $dom->clear() 212 | - Fixed the bug of text nodes' innertext 213 | - Fixed the bug of comment nodes' innertext 214 | - Fixed the bug of decendent selector with optional tags 215 | 216 | ## [0.97] - 2008-05-09 217 | ### Added 218 | - New node type "comment" (eg. $dom->find('comment')) 219 | - Add self-closing tags: 'base', 'spacer' 220 | - New example "simple_html_dom_utility.php" 221 | ### Changed 222 | - File and class name changed (html_dom_parser->simple_html_dom) 223 | ### Removed 224 | - ($dom->save_file) will not support anymore 225 | - Remove example "example_customize_parser.php" 226 | ### Fixed 227 | - Fixed the bug of outertext (th) 228 | - Fixed the bug of regular expression escaping chars ($dom->find) 229 | - Fixed the bug while line-breaker and "\t" in tags 230 | 231 | ## [0.96] - 2008-04-27 232 | ### Added 233 | - Reference section in manual 234 | - Added traverse section in manual 235 | - Added the solution while server behind proxy in FAQ (Thanks to Yousuke Shaggy) 236 | - New method to remove attribute. 237 | - New DOM operations(first_child, last_child, next_sibling, previous_sibling) (Request #1936000) 238 | ### Changed 239 | - Now file_get_dom supports full file_get_contents parameters 240 | ### Fixed 241 | - Fixed the bug of self-closing tags in the end of file 242 | - Fixed the bug of blanks in the end of tag 243 | - Fixed some typo of testcase 244 | 245 | ## [0.95] - 2008-04-13 246 | ### Added 247 | - Supports tag name with namespace 248 | ### Changed 249 | - New attribute filters (Thanks to Yousuke Kumakura) 250 | - Refine structure of testcase 251 | ### Fixed 252 | - Fix the bug of optional-closing tags 253 | - Fix the bug of parsing the line break next to the tag's name 254 | 255 | ## [0.94] - 2008-04-06 256 | ### Added 257 | - Add FAQ section in manual 258 | ### Fixed 259 | - Fixed infinity loop while the source content is BAD HTML 260 | - Fixed the bug of adding new attributes to self closing tags 261 | - Fixed the bug of customize parser without $dom->remove_noise() --------------------------------------------------------------------------------