Glyndwr Bartlett

Ranch Hand
+ Follow
since Jul 30, 2018
I am not a programmer. I am learning as I go in order to create an award application for Scouts.
Australia
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
4
Received in last 30 days
0
Total given
24
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Glyndwr Bartlett

Hi Bear,

"It does work on a Windows touch screen (Chrome, Explorer, Edge, Firefox)." So yes I have tested it elsewhere. I have not found this behaviour anywhere else. I have not tested it on Linux yet. :-)

Kind regards,

Glyn
I am creating a bootstrap button dynamically. When I select it on an iPad the colour changes however it does not trigger the form submission. It does work on a Windows touch screen (Chrome, Explorer, Edge, Firefox).

The code is:

CSS:



js:



html:

     
Hi Paul,

OK, a slight misunderstanding, resulting from my poorly written question. This is not in production yet, I just want to make sure that it will not go wrong in production (I am trying to be preemptive). Secondly, this is an Event with a program each day (this code allows the owner to move the programs from one day to another). The person who created the Event is the only who can update the daily programs. So, therefore, I take it that the three will always sets of statements will always be executed in the correct order, as no one else will be performing this task at the same time?

Kind regards,

Glyn
Hi Paul,

Sorry; however, your reply does not make sense to me. I read it that they will be executed one by one in the correct order; however, they may be executed simultaneously. How can both occur?

I can not find any information on how to wrap the three updates in a transaction. The only thing I found was to place "START TRANSACTION;" before the the three updates and then "COMMIT;" after them. However, that gives an error "START can not be resolved to a type".

This is my full code:



Kind regards,

Glyn
I am swapping two dates so I want to ensure that the prepared statement updates occur in the correct order (i.e., multi-threading and system performance do not affect the order). This is hard to test (i.e., it is obvious if it goes wrong in the test environment; however, sometime it does not go wrong until it is in the production environment which has a different performance) so I ask my learned colleagues will the following always occur in the correct order:





I am also very open to a better way of coding this.

Kind regards,

Glyn
I also would find this interesting. I am currently reading up on Handlebars. So far I do not see how that is any better than html strings. What am I missing?

Kind regards,

Glyn
Hi Stephan and Bear,

You are both absolutely right and I appreciate your input. I have started reading up on this (Handlebars especially). In the mean time I need to get the current code to work.

Bear - "unless another element is layered over it capturing the mouse clicks." Brilliant! I have the following css:



This is so I can set a dropped item as dragable so it can be removed as per:



So the solution is more css:



What I can not figure out is why the overlay is reaching down one row and to the right?

Kind regards,

Glyn


I am inserting a table row after the current row by clicking on a button. The row is inserted as required; however, the input fields, after the first, and button at the end of the row are not working. The input fields can not be clicked on to add data; however, I can tab into them to add data. The button at the end of the row does not register a click. You can tab to the button and hit enter and it works (tabbing to it and clicking does not).

The existing row is:



The function to add a new row is:



This is what it looks like with the new row added:

This is my solution (I have not implemented Bear's valuable suggestion yet):

Add the table and sub-table:



Handle the dropping of the item, make the field non droppable (only on drop on each row), make the div overlay of the dropped field draggable so it can be removed, add a new row to drop to:



Parse the tables:

Hi Bear,

This is great. I now have some more reading to do :-)

I have almost fixed my original issue. It has taken a lot of trial and error and finding incremental answers along the way. I will post the solution when completed.

Kind regards,

Glyn
Hi Bear, Thank you so much. This is what I need - "to be taught how to fish" :-). I have done some quick reading and people seem to be split on whether to use HTML strings vs jQuery. So far:

If you are creating a small amount then jQuery runs faster. However, what is a small amount vs large amount. The readings are mute on this.
HTML strings are easier to read than jQuery.

I would be very interested in an expansion on "While it makes for a lot of code, it's code rather than an HTML blob in the script. And it's essential if there are decisions to be made while building the DOM."

First, "it's code rather than an HTML blob in the script". What is important about this?

Second, "it's essential if there are decisions to be made while building the DOM". Why is it essential?

Can I get your book as an eBook?

Once again thank you so much for your help.
Hi Bear, In a word - ignorance :-) How should I be doing this please? I am not a programmer and am learning as I go for a not for profit organisation in my spare time.
I am trying to dynamically create a table (sub table) within a dynamically created table. I then complete the input fields in the table and drag items into the sub table. I then want to parse the table and sub table so I can store the contents in a database. This all works up to parsing the sub table. That I can not get to work. The class in "if ($.trim($(this).hasClass('dragabbleRemove'))) {" is not found. I can not find the div that was dragged into the table. The code is:

Add the table and sub table:



Handle the dropping of the item, make the filed non droppable (only on drop on each row), make the draggable so it can be removed, add a new row to drop to:



Parse the tables:

Thank you I will read up on this.

Kind regards,

Glyn