Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

31 Excellent

1 Follower

About jimfog

  • Rank
    Dedicated Member
  • Birthday 10/28/1979

Previous Fields

  • Languages
    Englsh, Greek

Contact Methods

  • MSN

Profile Information

  • Location
    Athens, Greece
  • Interests
    Computing, in any form of it, whether is web development, control theory or other, enjoy reading history books, especially WWII books, movies, fast cars(i do not have one, just a humble toyota yaris).

Recent Profile Visitors

25,931 profile views
  1. thanks for the answer,,,I just want your opinion in this code below since I wrote it BEFORE you answer. thanks again $i=0; while($i<count($_POST['services'])){ if(array_search($_POST['services'][$i], array_column($serviceslist, "serviceID"))===false) { echo json_encode('nosuchservice'); return; } $i++; }
  2. I have 2 arrays $_POST['services'][0]);///this is '31'....but it can contain more than one value $serviceslist);...this is a multidimentional array array(1) { [0]=> array(2) { ["service"]=> string(7) "haircut" ["serviceID"]=> int(31) } } I tried the following code....but it does not work and the reason being it assumes that $servicelist is one-dimentional array. if (is_array($_POST["services"])) { $i=0; while($i<count($_POST['services'])) { if ((in_array($_POST['services'][$i],$serviceslist)
  3. I have a JS datetime object such as this. start =Wed Mar 31 2021 09:00:00 GMT+0300 (Eastern European Summer Time) And I am using the localedatestring and localetimestring to format it. var startsend=info.start.toLocaleDateString() + 'T' + info.start.toLocaleTimeString('el-GR', { hour12: false }); I do not undestand why console longing the above will produce a portion of the result date in a hyperlink format...
  4. now...when error callback of ajax request fires I just display a message to the user....but how am I going to be notified for the reason the request failed...I mean me the dev. Of course I have not intention showing technial details to the end user..the aim is that such info(must somehow reach me)..any suggestions?
  5. I want to remove the clickhandler from this element here https://jsfiddle.net/fiddlehunt/gvtLd3e9/40/...a tooltip is attached to it. No jquery is used here..so I must resort to nativeJS...namely removeListener. I know that to use removeListener I must know the method/function used originally in the addeventListener..which I do not. SO...what can I do to remove the listener?
  6. is it possible to access BB view function outside the view definition...inside a jquery click handler for example: Here is a view and a click hendler..the handler is at line 21. I have tried several things before asking here... backbone example
  7. well the code works...I did not expect to work cause I had made some assumptions--which were wrong of course...I have 2 questions though. why not do this with PHP enbedded in the HTML...why resorting to JS...something like this: <div <?php echo ($schedstatus == 1) ? "style='display:none;'" : "style='display:block;'" ?> id="modal">...... I have come to understand that code in a JS file tha resides INSIDE the document on load function...runs after the HTML/document is loaded...that said the modal should be shown(my assumption) and hidden WHEN the code insid
  8. I have a textarea form that the user fills to inform why he/she is closing its business...no more than 200 chars. Suppose that he goes to edit that and clicks the cancel button..in such a case whatever he/she has typed must be replaced by the original text. this original text comes from the database and must be available somehwere in the DOM(in case it is needed such as the case of cancel). I was thinking the data attr but for various reasons I do not think you can store there so much text... What are my alternatives?
  9. Depending on a specific value taken from the database....a popup is hidden or shown in a page. The htlm of the popup is there but when the value is true(that comes from the db) with jquery I hide it. That is I get the value in JS....the problem with this approach is that(in case the popup is to be hidden) on page refresh the popup appears for less that a second and then disappears. Bad for UX. How I could make it that when the popup is hidden does not appear at all on refresh. Iis it better maybe to handle it server-side? I hear opinions.
  10. jimfog

    mvc or no mvc

    I am not coding based on MVC...my progect is not big...it works though..ok it is not the cleaner solution...but I am in a tight schedule...is there a compelling reason to change the code to MVC...what do you think?
  11. I am building an app where a table holds business users-businesses data: CREATE TABLE `business_users` ( `crID` mediumint unsigned NOT NULL, `bus_user_type` smallint DEFAULT NULL, `pack_selected` smallint unsigned NOT NULL, `sched_entered` tinyint(1) DEFAULT NULL, PRIMARY KEY (`crID`), KEY `fk_business_users_buz_usertype1_idx` (`bus_user_type`), KEY `pack` (`pack_selected`), CONSTRAINT `fk_business_users_buz_usertype1` FOREIGN KEY (`bus_user_type`) REFERENCES `buz_usertype` (`Type_id`), CONSTRAINT `fk_business_users_users1` FOREIGN KEY (`crID`) REFERENCES `users` (`
  12. You are absolutely right....do not know what I was thinking... This is better now https://jsfiddle.net/fiddlehunt/Lnt74wje/62/ Still I must do it like this-your sugestion is better:
  13. Ι do not get it....do you mean something like this https://jsfiddle.net/fiddlehunt/Lnt74wje/45/ The results are not the desired...
  14. thanks...there is one last detail. when the user clicks the doc radio and then some other radio the search box stays there(unwanted)...AND subsequent clicks of the doctor radio(after clicking othe radio buttons) displays many search boxes in the DOM-besides the doctor radio button. How to tackle these two. I have thought some solutions but I want to hear your opinion.
  • Create New...