Lines Matching refs:class

128 class simple_html_dom_node
568 list($tag, $id, $class, $attributes, $cmb) = $selector;
644 // Check if all class(es) exist
645 if ($pass && $class !== '' && is_array($class) && !empty($class)) {
646 if (isset($node->attr['class'])) {
647 $node_classes = explode(' ', $node->attr['class']);
653 foreach($class as $c) {
864 * [3] - class names (including dots)
867 * followed by the class name (one or more words and hyphens)
1161 // Look in the tag to see if there is a class or id specified that has
1166 // class or id that has an img selector that specifies a height or width
1167 // Note that in this case, the class or id will have the img subselector
1171 // If the class or id is specified in a SEPARATE css file thats not on
1194 function addClass($class)
1196 if (is_string($class)) {
1197 $class = explode(' ', $class);
1200 if (is_array($class)) {
1201 foreach($class as $c) {
1202 if (isset($this->class)) {
1206 $this->class .= ' ' . $c;
1209 $this->class = $c;
1214 $debug_object->debug_log(2, 'Invalid type: ', gettype($class));
1219 function hasClass($class)
1221 if (is_string($class)) {
1222 if (isset($this->class)) {
1223 return in_array($class, explode(' ', $this->class), true);
1227 $debug_object->debug_log(2, 'Invalid type: ', gettype($class));
1234 function removeClass($class = null)
1236 if (!isset($this->class)) {
1240 if (is_null($class)) {
1241 $this->removeAttribute('class');
1245 if (is_string($class)) {
1246 $class = explode(' ', $class);
1249 if (is_array($class)) {
1250 $class = array_diff(explode(' ', $this->class), $class);
1251 if (empty($class)) {
1252 $this->removeAttribute('class');
1254 $this->class = implode(' ', $class);
1390 class simple_html_dom
2125 // PaperG: If this is a "class" selector, lets get rid of the preceeding
2126 // and trailing space since some people leave it in the multi class case.
2127 if ($name === 'class') {