[Solved] Get Data with PHP [closed]

Change: $output .= $slide[‘slideshow_caption_title’])) $data .= ‘<h1 ‘.$font_style.’>’.$slide[‘slideshow_caption_title’].'</h1>’; to: $output .= $slide[‘slideshow_caption_title’]; $output .= ‘<h1 ‘.$font_style.’>’.$slide[‘slideshow_caption_title’].'</h1>’; and add: echo $output; after: $output .= “</div><!– end .relThumb –>\n”; 4 solved Get Data with PHP [closed]

[Solved] Php if session declare variable

I am not clear about question. as far as i understood check the below code <?php session_start(); // this is the first thing to do if(isset($_SESSION[‘admin_level’])){ $_SESSION[‘admin_level’]=10; //Set admin level if not available } $var=($_SESSION[‘admin_level’]==10)?”newclient”:”oldclient”; $qry=”SELECT * FROM client where client_status=””.$var.”””; 4 solved Php if session declare variable

[Solved] Replace with php each font size=”” to font-size: ; how to? [closed]

You can use preg_replace(). http://php.net/manual/en/function.preg-replace.php $str=”Hello <font size=”4″>today</font> is my <font size=”3″>special day</font> and am <font size=”11″>ready</font> for it…”; preg_replace(‘/<font size=”(\d+)”>(.+?)<\/font>/’, ‘<span style=”font-size:$1;”>$2</span>’, $str) Output: Hello <span style=”font-size:4;”>today</span> is my <span style=”font-size:3;”>special day</span> and am <span style=”font-size:11;”>ready</span> for it… 4 solved Replace with php each font size=”” to font-size: ; how to? [closed]

[Solved] echo value from DB as a Link in PHP/HTML table [closed]

You must use echo for print value like: echo “<td><a href=””.$row[“url’].”‘>”.$row[‘url’].”</a></td>”; or <td><a href=”https://stackoverflow.com/questions/60163422/<?php echo $row[“url’]; ?>’><?php echo $row[‘url’]; ?></a></td> 2 solved echo value from DB as a Link in PHP/HTML table [closed]

[Solved] Condition if elseif

you have to do something like this (assuming the array contains only 0,1,2) : $containsOne = false; $containstwo = false; // first loop over all results to check the content of the array foreach($results as $row){ if ($row[‘age’] == 1){ $containsOne = true; } if($row[‘age’] == 2){ $containsTwo = true; } } // once the … Read more

[Solved] Changing the source php [closed]

Use date to find the day of the week, using l. <?php echo “<iframe src=”http://cidadehoje.pt/player/”. strtolower(date(“l’)) .”.php’></iframe>”; solved Changing the source php [closed]

[Solved] Giving wrong day of week in PHP

You need to use date format “Y-m-d” to get the result you want. $date=”2017/06/07″ means June 07, 2017. If you want to get the day of July 06, 2017 then change $date=”2017/06/07″; To $date=”2017/07/06″; 0 solved Giving wrong day of week in PHP

[Solved] Regular Expressions pattern to extract particular digits from text [closed]

Try this: \b(?:256\d{9}|07[17-9]\d{8})\b Explanation: <!– \b(?:256\d{9}|07[17-9]\d{8})\b Options: ^ and $ match at line breaks; free-spacing Assert position at a word boundary «\b» Match the regular expression below «(?:256\d{9}|07[17-9]\d{8})» Match either the regular expression below (attempting the next alternative only if this one fails) «256\d{9}» Match the characters “256” literally «256» Match a single digit 0..9 … Read more