Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
functions [2020/04/06 12:12]
aducomadmin [PHsPeed functions (general)]
functions [2020/04/06 12:13] (current)
aducomadmin [PHsPeed functions (general)]
Line 9: Line 9:
 |isLoggedOn|Testst if the current users is logged on|isLoggedOn()|true or false|if(isLoggedOn()) { … }| |isLoggedOn|Testst if the current users is logged on|isLoggedOn()|true or false|if(isLoggedOn()) { … }|
 |phspCrypt|Encrypts and Decrypts data.|phspCrypt($string,​ $mode)|string|available modes are: '​e'​ for encryption and '​d'​ for description. The key and salt used is setup in the project properties. This function is used by PHsPeed to store database credentials,​ emailing options etc. Once set in the IDE then do not change as this will make the encrypted files unreadable. \\  \\ Sample: $mystr=phspCrypt($enc,​ '​e'​);​| |phspCrypt|Encrypts and Decrypts data.|phspCrypt($string,​ $mode)|string|available modes are: '​e'​ for encryption and '​d'​ for description. The key and salt used is setup in the project properties. This function is used by PHsPeed to store database credentials,​ emailing options etc. Once set in the IDE then do not change as this will make the encrypted files unreadable. \\  \\ Sample: $mystr=phspCrypt($enc,​ '​e'​);​|
-|PHP redirect|Redirects current form to another page.|phspRedirect($url,​ $origin=''​)''​ |nothing|''​Redirects to another module. ​$origin ​can be used as the recipient so that the called application can return. Sample: phspRedirect('​main.php','​myroutine'''​);​|+|PHP redirect|Redirects current form to another page.|phspRedirect($url,​ $origin=''​)''​ |nothing|Redirects to another module. ​Origin is optionas and can be used to pass the current module ​as a recepient.|
 |rtrSubmitBtn|Retrieves the id of the button clicked|rtrSubmitBtn();​|string|This function will return the button clicked. It is only to be used in the submit process and is not usable in ajax events. If you have more buttons on the form and want to take action depending on the submit button clicked then this function is useful. \\ Sample: \\  \\ $key=rtrSubmitBtn();​ \\ if($key=='​mail_btn_1'​) { …. } \\  \\ The name of the button is the name that is used in its constructor (#module _ #name). So if the PHP modules name is '​myapp'​ and the button is called '​mybtn'​ then the function would return '​myapp_mybtn'; ​ | |rtrSubmitBtn|Retrieves the id of the button clicked|rtrSubmitBtn();​|string|This function will return the button clicked. It is only to be used in the submit process and is not usable in ajax events. If you have more buttons on the form and want to take action depending on the submit button clicked then this function is useful. \\ Sample: \\  \\ $key=rtrSubmitBtn();​ \\ if($key=='​mail_btn_1'​) { …. } \\  \\ The name of the button is the name that is used in its constructor (#module _ #name). So if the PHP modules name is '​myapp'​ and the button is called '​mybtn'​ then the function would return '​myapp_mybtn'; ​ |
 |session_stop|Releases session variables and closes current session|session_stop()|nothing|This function will prevent data to be saved in a reusable session cookie after termination of the application.| |session_stop|Releases session variables and closes current session|session_stop()|nothing|This function will prevent data to be saved in a reusable session cookie after termination of the application.|