Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Barand last won the day on February 17

Barand had the most liked content!

Community Reputation

1,447 Excellent

About Barand

Profile Information

Recent Profile Visitors

60,911 profile views
  1. mysql> SELECT monthname(from_unixtime(target)) as Month -> , COUNT(*) as Total -> FROM production -> GROUP BY month(from_unixtime(target)); +----------+-------+ | Month | Total | +----------+-------+ | October | 3 | | November | 5 | +----------+-------+
  2. I have experienced difficulty in adding a new line after a quote at the bottom of a reply. I get round it by inserting a newline above the quote then dragging the quote box above that new line.
  3. I need a little thinking time. You've had weeks on this. PS. This has very little to do with the problem of drawing a signature
  4. Bear in mind that that is only one example. The same situation can occur at other places along the "input/store/output" process.
  5. It could be the HTML markup style when using quotes within quotes For example $name = "O'Sullivan"; echo " <form> Enter surname <input type='text' name='surname' value='$name'> <br> <button type='submit' >Submit</button> </form> "; displays Whereas $name = "O'Sullivan"; echo " <form> Enter surname <input type='text' name='surname' value=\"$name\"> <!-- changed quotes around $name --> <br> <button type='submit' >Submit</button> </form> "; displays You also need to ensure that prepared statements are used when updating your DB tables as this will correctly handle such surname data.
  6. If by "Issue" you are referring to the various item checks then no change would be required. For example, it will be possible to filter all those that fail the "Googly Eyes Check" or "the "Lidar Rotation Check". If, however, by issue you are referring a lower level of detail within these checks then my earlier comment stands and change is needed.
  7. 1. For your Save as CSV Email report Print report You are going to need image files for each of the signatures if they are to be included (via image URL). You will also need to master PDFs for the printed versions. 2. If you want a breakdown by "issue" then your visit_item data needs an issue code. You cannot rely on freeform text - minor mis-spellings corrupt the data. You probably also need a table defining the issues that can arise for each item. Instead of comment text, the tech would select from a menu. You data capture app is in for some significant changes. 3. What is "BAR number"? I do not see it in the data.
  8. try $hashtags = '#adf #234432 #fwerfw'; $array = explode(' ', $hashtags); foreach ($array as $var) { echo "<div style='width: 200px; border: 1px solid red; margin: 8px; padding: 8px'>$var</div>"; }
  9. With care not to use any features that have been added within the last five years, or any that are about to be removed in later versions (to protect against future updates of your implementation), then it can be achieved. However, it's always best to be up to date with version used, and as you are pre 5.6, I would recommend an update. (Having said that, I'm a couple of versions behind (7.2) )
  10. All those languages yet the term "normalize" remains a totally foreign concept.
  11. You are using an outdated version of PHP (pre v5.6) Change $act = (sqrt($dx**2 + $dy**2) > 30) ? 'M' : 'L'; // check distance between successive points to $act = (sqrt($dx*$dx + $dy*$dy) > 30) ? 'M' : 'L'; // check distance between successive points
  12. This the function used to create the left-hand side images (uses scaleable vector graphics (SVG) ) function drawImage($xcoords, $ycoords) { $xa = $xcoords[0]=='[' ? json_decode($xcoords, 1) : explode(',', $xcoords); // put x coords into an array $ya = $ycoords[0]=='[' ? json_decode($ycoords, 1) : explode(',', $ycoords); // put x coords into an array $w = max($xa)+10; // get the max coord values so we know the size $h = max($ya)+10; $path = ''; $px = $py = -31; // ensure we Move to first point foreach ($xa as $i => $x) { // loop through arrays $y = $ya[$i]; // pairing the ith x with the ith y $dx = $x-$px; $dy = $y-$py; $px = $x; $py = $y; $act = (sqrt($dx**2 + $dy**2) > 30) ? 'M' : 'L'; // check distance between successive points $path .= "$act $x $y "; // define line to x y } // create svg object $w x $h to display image $im = "<svg width='$w' height='$h'> <path d='$path' stroke='#000' stroke-width='2' fill='none'/> </svg>"; return $im; } The image on the right was an experiment to create a .png version. I don't think the quality is as good as vector ones.
  13. One table for likes , one for dislikes and and a third for views Perhaps combine like/dislikes with a flag column to distinguish
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.