Jump to content

Isabelleg

Members
  • Posts

    11
  • Joined

  • Last visited

Everything posted by Isabelleg

  1. thanks for getting back so quickly ! interesting. when you talk about "host page" are you referring to a CMS ? or are you coding from scratch ? trying to get some ideas on how to fully integrate Caspio's DP with bootstrap (and not using their tech-tip for responsive layout). If you have any insight ..
  2. Really good post ! thanks for sharing. 2 little notes : - Class='collapse' should be an attribute of <div class='col-md-3'> not its child, because it will break on the second line if you have 3+12 (even if 3 is empty) no ? - and in style they should add .collapse { display:none; } .show { display:flex; } Now a question on the style of your tabular: is it responsive ? when you scale from 12 to 9, do you change your tabular's layout ? do you set your font to rem, although your viewport doesn't change, just the width of the div ...? I am really eager to exchange on the subject, as I am trying to get the best UI possible in a responsive layout using bootstrap (and it seems that it is your goal too!) Please link back to me so we can brainstorm on the subject. Best, And again thanks for sharing !
  3. i tried this and it's not working, am i missing something ? where do you get the function (e) ? function remName(a, { if(a.value=={ a.value=''; }else if(a.value==''){ a.value=b; }else{ a.value=a.value; } } function chkName(a, { if(a.value==''){ a.value=b; }else{ a.value=a.value; } } var valeur = document.getElementById("InsertRecordEMAIL").value; document.getElementById('InsertRecordEMAIL').onfocus = function( e ) { remName(e, valeur); } document.getElementById('InsertRecordEMAIL').onblur = function( e ) { chkName(e, valeur); }
  4. here is the caspio tutorial http://howto.caspio.com/customization/i ... areas.html but they don't provide the tutorial to reput the text onblur if no value has been entered.
  5. Hi Mike, heres a js to validate a north america phone number format, enjoy ! PS: this code will work if the end-user enter a 10 digits number - you have a field nammed "TEL" - you can add a button in your form to check if the function works : add a html block and paste: <input type="button" value="Click me!" onclick="tel();" /> (once you verified your code, you can hide your button with adding before the button <table style="display:none;"><td> and after the button </td></table> or you can delete it, because the code will be applied once the end-user will click "submit" - then on your footer paste : <SCRIPT LANGUAGE="JavaScript"> function tel() { var message = document.getElementById("InsertRecordTEL").value; // here you get what the end-user typed document.getElementById("InsertRecordTEL").value = (message.replace(/[^\d]/g, '')); // then you strip off all the spaces var message1 = document.getElementById("InsertRecordTEL").value; document.getElementById("InsertRecordTEL").value = ("(" + message1.substring(0,3) + ") " + message1.substring(3,6) + "-" + message1.substring(6,10)); } document.getElementById("caspioform").onsubmit=tel; </SCRIPT>
  6. Hi Jay, heres a js to validate a north america phone number format, enjoy ! PS: this code will work if the end-user enter a 10 digits number - you have a field nammed "TEL" - you can add a button in your form to check if the function works : add a html block and paste: (once you verified your code, you can hide your button with adding before the button or you can delete it, because the code will be applied once the end-user will click "submit"- then on your footer paste : function tel() { var message = document.getElementById("InsertRecordTEL").value; // here you get what the end-user typed document.getElementById("InsertRecordTEL").value = (message.replace(/[^\d]/g, '')); // then you strip off all the spaces var message1 = document.getElementById("InsertRecordTEL").value; document.getElementById("InsertRecordTEL").value = ("(" + message1.substring(0,3) + ") " + message1.substring(3,6) + "-" + message1.substring(6,10)); } document.getElementById("caspioform").onsubmit=tel;
  7. Hi, Caspio provides the js to auto clear on focus but don't go further to recall the text onblur ... i have a js but can't adapt it to caspio .. any help would be much appreciated. function remName(a, { if(a.value=={ a.value=''; }else if(a.value==''){ a.value=b; }else{ a.value=a.value; } } function chkName(a, { if(a.value==''){ a.value=b; }else{ a.value=a.value; } } var valeur = document.getElementById("InsertRecordEMAIL").value; document.getElementById('InsertRecordEMAIL').onfocus = remName(this, 'valeur'); document.getElementById('InsertRecordEMAIL').onblur = chkName(this, 'valeur');
  8. Hi Barbara, thanks for the reply. i'll check them. Best wishes Isabelle
  9. Hi, I'm quite new in programing in JS. In my table, i gather my clients, my management companies and my brokers. I've created a submission form to add new entries. But those 3 types of contacts don't need the same information : Client need : name, address, type of interest Management need : name Broker need : name, email (of course i have all those fields in my table) but i would like to avoid creating a submission form for each, requesting the different info regarding the type. I would like to have 1 submission form, where the first field is a dropdown menu to pick either a client, management or broker, (and at first there would be only this field to be displayed) then according to the first selection, the submission form will display the rest of the needed fields. Can you provide me the javascript ? i've checked in Caspio forum, but couldn't really find help. thanks a lot
×
×
  • Create New...