If then # SQLQUERY contains an empty string.Įcho "There have been no new documents added to the CMS in the last 7 days." > /root/bin/mailtextĬonst jobContainer = document.querySelector('.job-description') I mean:Įcho "TO:" $RECIPIENTS > /root/bin/mailtextĮcho "SUBJECT:" $SUBJECT $DATE > /root/bin/mailtextĮcho "SELECT name AS NAME,MIN(id) as ID,MIN(created_at) as CREATED,MIN(CONCAT(' as URL from pages WHERE deleted_at IS NULL AND name NOT LIKE 'AO%' AND name NOT LIKE 'KB%' AND name NOT LIKE 'Odoo%' AND name NOT LIKE 'WK%' AND draft=0 AND created_at > DATE_SUB(NOW(), INTERVAL 7 DAY) GROUP BY name \G" | mysql -u root -D bookstack > /root/bin/mailtextĬat /root/bin/mailtext | /usr/sbin/sendmail -tĭATE=$(date DATE_SUB(NOW(), INTERVAL 7 DAY) GROUP BY name \G" | mysql -u root -D bookstack)Įcho "FROM:" $SENDER > /root/bin/mailtext
DOWNLOAD IMAGEOPTIM HOW TO
Was this a classic SingleEntityAuthorUsers relationship I would have build it as a ManyToMany item, but here it's different.Īuthor would probably contain two ManyToOne relations (one with the User entity and one with either the Document or the Video entity) plus the entity type field, but I really don't know how to code the "Document orVideo`" part. The problem is that I cannot understand how to build this in Doctrine.
![download imageoptim download imageoptim](https://www.gratissoftware.nu/images2/imageoptim-2.jpg)
On another note you should switch to PDO as mysqli is not secure at all if you do not escape queries correctly.
![download imageoptim download imageoptim](https://www.displayblock.com/wp-content/uploads/2015/06/imageoptim.png)
That would automatically do the same thing over and over for every user that submits the form. User Form -> User Inputs Data (Submits Form) -> ajax handles the posting to the php file -> let ajax wait for a response from php on success -> refresh the page using jquery. Have you tried using ajax in the mix between the form and user inputs ?
![download imageoptim download imageoptim](https://moreinfo.thebigboss.org/moreinfo/photosimageupload2.png)
I re-read your question twice and it boggles me: "This all seems like a real headache, but I don't have anyone to ask about this, that's why I'm trying to push my luck in here.