Setting Path in LiveCode Server
Posted: Sun May 03, 2020 9:02 pm
Hi Everyone,
I'm a total NewBee with LiveCode. I'm an ex-Visual FoxPro user. I eventually want to create an app in LiveCode that runs on a web server. I obtained an account with LiveCode and am struggling with each step ... but what else do we have to do during these days of incarceration?
I'm trying to set the path to a folder on the LiveCode server to a folder to contain the text files used in the sample Notes app in the ABC''s intro to app building.
This function is in the Stack Script and called from both of the cards in the app one of which lists the entered notes and the other displays the individual note:
function notesFolder
-- if NotesApp folder is saved in the users documents folder
--return (specialFolderPath("documents") & "/NotesApp") -- this works for my local computer
-- to store notes in ("C:/LiveCode/Notes/NotesApp/") on my local drive I use Absolute Path
return ("C:/LiveCode/Notes/NotesApp/") -- this works for my local computer file setup
-- I tried Relative paths as well and only got listings from the Program Files folder where LiveCode runs from
HERE'S THE QUESTIONABLE CODE!!
-- attempts to store notes in ("/public_html/notes/NotesApp/") folder on my LiveCode Server account
--Error Message ... Exception thrown, see JavaScript console ... this same error with each of these attempts:
--return ("http:// ( my domain.) (my server) /notes/NotesApp/")
--return ("public_html/notes/NotesApp/")
--return ("/public_html/notes/NotesApp/")
--return ("notes/NotesApp/")
--return ("/notes/NotesApp/")
--return ("NotesApp/")
return ("/NotesApp/") -- last attempt
end notesFolder
Anyone interested in helping with my app ... let me know!!
I want to create an app that creates softball tournament schedules for my Maui Senior Softball League.
Thanks and stay safe everyone,
Lonnie
I'm a total NewBee with LiveCode. I'm an ex-Visual FoxPro user. I eventually want to create an app in LiveCode that runs on a web server. I obtained an account with LiveCode and am struggling with each step ... but what else do we have to do during these days of incarceration?
I'm trying to set the path to a folder on the LiveCode server to a folder to contain the text files used in the sample Notes app in the ABC''s intro to app building.
This function is in the Stack Script and called from both of the cards in the app one of which lists the entered notes and the other displays the individual note:
function notesFolder
-- if NotesApp folder is saved in the users documents folder
--return (specialFolderPath("documents") & "/NotesApp") -- this works for my local computer
-- to store notes in ("C:/LiveCode/Notes/NotesApp/") on my local drive I use Absolute Path
return ("C:/LiveCode/Notes/NotesApp/") -- this works for my local computer file setup
-- I tried Relative paths as well and only got listings from the Program Files folder where LiveCode runs from
HERE'S THE QUESTIONABLE CODE!!
-- attempts to store notes in ("/public_html/notes/NotesApp/") folder on my LiveCode Server account
--Error Message ... Exception thrown, see JavaScript console ... this same error with each of these attempts:
--return ("http:// ( my domain.) (my server) /notes/NotesApp/")
--return ("public_html/notes/NotesApp/")
--return ("/public_html/notes/NotesApp/")
--return ("notes/NotesApp/")
--return ("/notes/NotesApp/")
--return ("NotesApp/")
return ("/NotesApp/") -- last attempt
end notesFolder
Anyone interested in helping with my app ... let me know!!
I want to create an app that creates softball tournament schedules for my Maui Senior Softball League.
Thanks and stay safe everyone,
Lonnie