diff options
-rw-r--r-- | doc/Privacy.md | 7 | ||||
-rw-r--r-- | doc/Profiles.md | 36 | ||||
-rw-r--r-- | doc/debian_install.bb | 4 | ||||
-rw-r--r-- | doc/developer_function_primer.bb | 4 | ||||
-rw-r--r-- | doc/faq_admins.bb | 5 | ||||
-rw-r--r-- | doc/main.bb | 13 | ||||
-rw-r--r-- | doc/red2pi.bb | 4 | ||||
-rw-r--r-- | doc/troubleshooting.bb | 2 | ||||
-rw-r--r-- | install/INSTALL.txt | 125 | ||||
-rwxr-xr-x | mod/events.php | 33 | ||||
-rwxr-xr-x | view/tpl/event_form.tpl | 1 |
11 files changed, 107 insertions, 127 deletions
diff --git a/doc/Privacy.md b/doc/Privacy.md index 60e087e06..9519651eb 100644 --- a/doc/Privacy.md +++ b/doc/Privacy.md @@ -25,10 +25,6 @@ An individual computer or server connected to the RedMatrix. These are provided The system operator of an individual hub. -**spy network** - -Typically large centralised providers including but not limited to Facebook and Google. RedMatrix PRIVATE communications are designed to even be resistant to monitoring by the American NSA, however the technical capabilities of the NSA are not completely known and no guarantee of privacy against this organisation can be made. RedMatrix PUBLIC communications are not protected in any way. - ##Policies **Public Information** @@ -52,7 +48,7 @@ Comments to posts that were created by others and posts which are designated as **Private Information** -RedMatrix developers will ensure that any content you provide which is designated as PRIVATE will be protected against eavesdropping - to the best of their ability. Private content is generally hidden or obscured even from hub administrators. It is also stripped from email notifications. It is difficult but NOT impossible for this content to be seen by a hub administrator who is determined to monitor your communications. We consider this like the lock on the door of a house. It will generally keep the house safe, but a determined burgler will ignore the lock on the door and instead break a window. +RedMatrix developers will ensure that any content you provide which is designated as PRIVATE will be protected against eavesdropping - to the best of their ability. Private content is generally hidden or obscured even from hub administrators. It is also stripped from email notifications. It is difficult but NOT impossible for this content to be seen by a hub administrator. This is a side effect of the physical laws of the universe. Unfortunately, if a database needs to decrypt a post at display time, it must have the means to decrypt the post! End to end encryption is also provided and this CANNOT be seen, even by a determined administrator. ##Identity Privacy @@ -74,3 +70,4 @@ The RedMatrix RECOMMENDS that hub administrators provide a grace period of 1-2 d If you typically and regularly post content of an adult or offensive nature, you are STRONGLY encouraged to mark your account "NSFW" (Not Safe For Work). This will prevent the display of your profile photo in the directory except to viewers that have chosen to disable "safe mode". If your profile photo is found by directory administrators to be adult or offensive, the directory administrator MAY flag your profile photo as NSFW. There is currently no official mechanism to contest or reverse this decision, which is why you SHOULD mark your own account NSFW if it is likely to be inappropriate for general audiences. +#include doc/macros/main_footer.bb; diff --git a/doc/Profiles.md b/doc/Profiles.md deleted file mode 100644 index 1e9e0fe5e..000000000 --- a/doc/Profiles.md +++ /dev/null @@ -1,36 +0,0 @@ -Profiles -======== - -* [Home](help) - -Red has unlimited profiles. You may use different profiles to show different "sides of yourself" to different audiences. This is different to having different _channels_. Different channels allow for completely different sets of information. You may have a channel for yourself, a channel for your sports team, a channel for your website, or whatever else. A profile allows for finely graded "sides" of each channel. For example, your default public profile might say "Hello, I'm Fred, and I like laughing". You may show your close friends a profile that adds "and I also enjoy dwarf tossing". - -You always have a profile known as your "default" or "public" profile. This profile is always available to the general public and cannot be hidden (there may be rare exceptions on privately run or disconnected sites). You may, and probably should restrict the information you make available on your public profile. - -That said, if you want other friends to be able to find you, it helps to have the following information in your public profile... - -* Your real name or at least a nickname everybody knows -* A photo of **you** -* Your location on the planet, at least to a country level. - -Without this basic information, you could get very lonely here. Most people (even your best friends) will not try and connect with somebody that has a fake name or doesn't contain a real photo. - -In addition, if you'd like to meet people that share some general interests with you, please take a moment and add some "Keywords" to your profile. Such as "music, linux, photography" or whatever. You can add as many keywords as you like. - -To create an alternate profile, select "View Profile" from the menu of your Red Matrix site, then click on the pencil at your profile photo. You may edit an existing profile, change the profile photo, add things to a profile or create a new profile. You may also create a "clone" of an existing profile if you only wish to change a few items but don't wish to enter all the information again. To do that, click on the profile you want to clone and choose "Clone this profile" there. - -In the list of your profiles, you can also choose the contacts who can see a specific profile. Just click on "Edit visibility" next to the profile in question (only available for the profiles that are not your default profile) and then click on user images to add them to or remove them from the group of people who can see this profile. - -Once a profile has been selected, when the person views your profile, they will see the private profile you have assigned. If they are not authenticated, they will see your public profile. - -There is a setting which allows you to publish your profile to a directory and ensure that it can be found by others. You can change this setting on the "Settings" page. - -If you do not wish to be found be people unless you give them your channel address, you may leave your profile unpublished. - -**Keywords and Directory Search** - -On the directory page, you may search for people with published profiles. The search is typically for your nickname or part of your full name. However this search will also match against other profile fields - such as gender, location, "about", work, and education. You may also include "Keywords" in your default profile - which may be used to search for common interests with other members. Keywords are used in the channel suggestion tool and although they aren't visible in the directory, they are shown if people visit your profile page. - -Directory searches are also able to use "boolean" logic so that you can search for "+lesbian +Florida" and find those who's sexual preference (or keywords) contain the world "lesbian" and that live in Florida. See the section on "Topical Tags" on the [Tags-and-Mentions](help/Tags-and-Mentions) page for more information on performing boolean searches. - -On your Connnections page and in the directory there is a link to "Suggestions" or "Channel Suggestions", respectively. This will find channels who have matching and/or similar keywords. The more keywords you provide, the more relevant the search results that are returned. These are sorted by relevance. diff --git a/doc/debian_install.bb b/doc/debian_install.bb index f4e901dc6..866ee8e9f 100644 --- a/doc/debian_install.bb +++ b/doc/debian_install.bb @@ -1,7 +1,7 @@ [b]Installing On Debian[/b]
While following the instructions for any other installation will work on Debian, for this platform we also provide an install script
-which can be [zrl=http://beardyunixer.com:1234/?p=debian-install-script.git;a=tree]downloaded here[/zrl]
+which can be [url=http://gitweb.whogotzot.com/debian-install-script]downloaded here[/url]
[b]THIS SCRIPT IS MEANT TO BE RUN ON A NEW OR JUST REINSTALLED SERVER[/b]
@@ -17,7 +17,7 @@ For the initial setup git may not be installed on your server, to install git: If wget is installed try
-[code]wget "http://beardyunixer.com:1234/?p=debian-install-script.git;a=blob_plain;f=debian-setup.sh;hb=HEAD" -O debian-setup.sh[/code]
+[code]wget "http://gitweb.whogotzot.com/debian-install-script/snapshot/91e76332668509585d52d4fa3f5b81a728c67fa6.tar.gz" -O debian-setup.sh[/code]
To install wget:
[code]apt-get install wget[/code]
diff --git a/doc/developer_function_primer.bb b/doc/developer_function_primer.bb index 3d5fe82a9..3db853b82 100644 --- a/doc/developer_function_primer.bb +++ b/doc/developer_function_primer.bb @@ -20,13 +20,13 @@ Returns the global app structure ($a). (App:: is usually assigned to the global $a), so $a->get_observer() or get_app()->get_observer() - returns an xchan structure representing the current viewer if authenticated (locally or remotely).
-[b]get_config($family,$key), get_pconfig($uid,$family,$key)[/b]
+[b]get_config($family,$key), get_pconfig($uid,$family,$key), get_xconfig($xchan_hash,$family,$key)[/b]
Returns the config setting for $family and $key or false if unset.
[b] set_config($family,$key,$value), set_pconfig($uid,$family,$key,$value)[/b]
-Sets the value of config setting for $family and $key to $value. Returns $value. The config versions operate on system-wide settings. The pconfig versions get/set the values for a specific integer uid (channel_id).
+Sets the value of config setting for $family and $key to $value. Returns $value. The config versions operate on system-wide settings. The pconfig versions get/set the values for a specific integer uid (channel_id). The xconfig version get/sets the value for a specific xchan hash - generally used for remote users.
[b]dbesc()[/b]
diff --git a/doc/faq_admins.bb b/doc/faq_admins.bb index 60c1be5a8..e4541035b 100644 --- a/doc/faq_admins.bb +++ b/doc/faq_admins.bb @@ -43,6 +43,11 @@ valid SSL certificate rather than disabling port 443. 4) Rsync everything in custom/ (this will only exist if you have custom modules) 5) Dump and restore DB. +[*] +[b]How do I set the default homepage for logged out viewers?[/b] + +Use the custom_home addon available in the main addons repository. + [/ul] #include doc/macros/main_footer.bb; diff --git a/doc/main.bb b/doc/main.bb index 5502db67d..b7155fa1e 100644 --- a/doc/main.bb +++ b/doc/main.bb @@ -24,7 +24,7 @@ Zot is the great new communicaton protocol invented especially for the Red Matri [zrl=[baseurl]/help/cloud]Cloud Storage[/zrl]
[zrl=[baseurl]/help/remove_account]Remove Channel or Account[/zrl]
-[size=large][b]Using the Red Matrix[/b][/size]
+[size=large][b]Members Help[/b][/size]
[zrl=[baseurl]/help/tags_and_mentions]Tags and Mentions[/zrl]
[zrl=[baseurl]/help/webpages]Web Pages[/zrl]
[zrl=[baseurl]/help/bbcode]BBcode reference for posts and comments[/zrl]
@@ -32,20 +32,15 @@ Zot is the great new communicaton protocol invented especially for the Red Matri [zrl=[baseurl]/help/cloud_desktop_clients]Cloud Desktop Clients[/zrl]
[zrl=[baseurl]/help/AdvancedSearch]Advanced Directory Search[/zrl]
[zrl=[baseurl]/help/addons]Help With Addons[/zrl]
-[zrl=[baseurl]/help/nomadic-identity]Got Zot? Nomadic Identity, Channel Cloning And More[/zrl]
[zrl=[baseurl]/help/diaspora_compat]Diaspora Communications Compatibility (Diaspora and Friendica)[/zrl]
-
-[size=large][b]Frequently Asked Questions For Members[/b][/size]
[zrl=[baseurl]/help/faq_members]FAQ For Members[/zrl]
-[size=large][b]For Hub Administrators[/b][/size]
+[size=large][b]Administrators Help[/b][/size]
[zrl=[baseurl]/help/install]Install[/zrl]
[zrl=[baseurl]/help/debian_install]Easy Install on Debian via script[/zrl]
[zrl=[baseurl]/help/red2pi]Installing Red on the Raspberry Pi[/zrl]
-[zrl=[baseurl]/help/problems-following-an-update]Problems Following A Software Update[/zrl]
[zrl=[baseurl]/help/troubleshooting]Troubleshooting Tips[/zrl]
-
-[size=large][b]Frequently Asked Questions For Hub Admins[/b][/size]
+[zrl=[baseurl]/help/hidden_configs]Tweaking RedMatrix's Hidden Configurations[/zrl]
[zrl=[baseurl]/help/faq_admins]FAQ For Admins[/zrl]
[size=large][b]Technical Documentation[/b][/size]
@@ -69,7 +64,6 @@ Zot is the great new communicaton protocol invented especially for the Red Matri [zrl=[baseurl]/help/to_do_code]To-Do list for Developers[/zrl]
[zrl=[baseurl]/help/git_for_non_developers]Git for Non-Developers[/zrl]
-
[size=large][b]Frequently Asked Questions For Developers[/b][/size]
[zrl=[baseurl]/help/faq_developers]FAQ For Developers[/zrl]
@@ -79,5 +73,6 @@ Zot is the great new communicaton protocol invented especially for the Red Matri [url=https://github.com/friendica/red-addons]Addon Website[/url]
[url=https://zothub.com/channel/one]Development Channel[/url]
+[url=[baseurl]/help/credits]RedMatrix Credits[/url]
[size=large][b]About This Red Matrix Site[/b][/size]
[zrl=[baseurl]/siteinfo] [baseurl]/siteinfo[/zrl]
diff --git a/doc/red2pi.bb b/doc/red2pi.bb index d05cc57dd..48b7f6d38 100644 --- a/doc/red2pi.bb +++ b/doc/red2pi.bb @@ -1,9 +1,5 @@ [b]How to install the Red Matrix on a Raspberry Pi[/b]
-[zrl=[baseurl]/help/main] Back to the main page[/zrl]
-Last update 2014-02-22
-[hr]
-
You just bought a Raspberry Pi and want to run the RED Matrix with your own domain name?
Then this page is for you! You will:
diff --git a/doc/troubleshooting.bb b/doc/troubleshooting.bb index d71b5f576..d5e1a29dc 100644 --- a/doc/troubleshooting.bb +++ b/doc/troubleshooting.bb @@ -3,4 +3,6 @@ [li][zrl=[baseurl]/help/technical_faq]Technical FAQ[/zrl][/li]
[li][zrl=[baseurl]/help/problems-following-an-update]Problems following an update[/zrl][/li]
+#include doc/macros/troubleshooting_footer.bb;
#include doc/macros/main_footer.bb;
+
diff --git a/install/INSTALL.txt b/install/INSTALL.txt index 8ec919369..f5edf009f 100644 --- a/install/INSTALL.txt +++ b/install/INSTALL.txt @@ -1,4 +1,3 @@ - Red Matrix Installation We've tried very hard to ensure that the Red Matrix will run on commodity @@ -46,47 +45,48 @@ allow you to use a non browser-valid certificate. This restriction is incorporated because public posts from you may for example contain references to images on your own hub. If your certificate is not known by the internet browser of users they get a warning message complaining about -some security issues. Although these complains are not the real truth - there -are no security issues with your encryption! - the users may be confused, -nerved or even worse may become scared about Red Matrix having security issues. +the invalid certificate. + Free "browser-valid" certificates are available from providers such as StartSSL. - + If you do NOT use SSL, there may be a delay of up to a minute for the initial install script - while we check the SSL port to see if anything responds there. When communicating with new sites, Red Matrix always attempts connection on the -SSL port first, before falling back to a less secure connection. +SSL port first, before falling back to a less secure connection. If you do not +use SSL, your webserver must not listen on port 443 at all. 1. Requirements - - Apache with mod-rewrite enabled and "AllowOverride All" so you can use a -local .htaccess file + - Apache with mod-rewrite enabled and "AllowOverride All" so you can use a + local .htaccess file - - PHP 5.3+. The later the better. + - PHP 5.3+. The later the better. - - PHP *command line* access with register_argc_argv set to true in the -php.ini file - and with no hosting provider restrictions on the use of exec() -and proc_open(). + - PHP *command line* access with register_argc_argv set to true in the + php.ini file - and with no hosting provider restrictions on the use of + exec() and proc_open(). - - curl, gd (with at least jpeg and png support), mysqli, mbstring, mcrypt, and openssl extensions. The imagick extension is not required but desirable. + - curl, gd (with at least jpeg and png support), mysqli, mbstring, mcrypt, + and openssl extensions. The imagick extension is not required but desirable. - - some form of email server or email gateway such that PHP mail() works + - some form of email server or email gateway such that PHP mail() works - - Mysql 5.x or MariaDB + - Mysql 5.x or MariaDB + + - ability to schedule jobs with cron. - - ability to schedule jobs with cron. + - Installation into a top-level domain or sub-domain (without a + directory/path component in the URL) is REQUIRED. - - Installation into a top-level domain or sub-domain (without a -directory/path component in the URL) is REQUIRED. +2. Unpack the RedMatrix files into the root of your web server document area. + + If you copy the directory tree to your webserver, make sure that you + also copy .htaccess - as "dot" files are often hidden and aren't normally + copied. -2. Unpack the Red Matrix files into the root of your web server document area. - - - If you copy the directory tree to your webserver, make sure - that you also copy .htaccess - as "dot" files are often hidden - and aren't normally copied. - - - If you are able to do so, we recommend using git to clone the - source repository rather than to use a packaged tar or zip file. - This makes the software much easier to update. The Linux command - to clone the repository into a directory "mywebsite" would be + - If you are able to do so, we recommend using git to clone the source + repository rather than to use a packaged tar or zip file. This makes the + software much easier to update. The Linux command to clone the repository + into a directory "mywebsite" would be git clone https://github.com/friendica/red.git mywebsite @@ -94,18 +94,20 @@ directory/path component in the URL) is REQUIRED. git pull - - make sure folders *store/[data]/smarty3* and *store* exist and are writable by webserver + - make sure folders *store/[data]/smarty3* and *store* exist and are + writable by the webserver - mkdir -p "store/[data]/smarty3" + mkdir -p "store/[data]/smarty3" chmod -R 777 store - [This permission (777) is very dangerous and if you have sufficient - privilege and knowledge you should make this directory writeable only - by the webserver. In many shared hosting environments this may be - difficult without opening a trouble ticket with your provider. The - above permissions will allow the software to work, but are not - optimal.] + [This permission (777) is very dangerous and if you have sufficient + privilege and knowledge you should make these directories writeable + only by the webserver and, if different, the user that will run the + cron job (see below). In many shared hosting environments this may be + difficult without opening a trouble ticket with your provider. The + above permissions will allow the software to work, but are not + optimal.] - For installing addons @@ -113,21 +115,20 @@ directory/path component in the URL) is REQUIRED. cd mywebsite - - Then you should clone the addon repository (separately) + - Then you should clone the addon repository (separately) - git clone https://github.com/friendica/red-addons.git addon + git clone https://github.com/friendica/red-addons.git addon - - For keeping the addon tree updated, you should be on you addon tree and issue a git pull + - For keeping the addon tree updated, you should be on you addon tree and + issue a git pull cd mywebsite/addon - - git pull + git pull 3. Create an empty database and note the access details (hostname, username, password, database name). - 4. If you know in advance that it will be impossible for the web server to write or create files in your web directory, create an empty file called .htconfig.php and make it writable by the web server. @@ -139,12 +140,12 @@ website. 6. *If* the automated installation fails for any reason, check the following: - - ".htconfig.php" exists - If not, edit htconfig.php and change system settings. Rename -to .htconfig.php + - ".htconfig.php" exists + If not, edit htconfig.php and change system settings. Rename + to .htconfig.php - Database is populated. - If not, import the contents of "database.sql" with phpmyadmin -or mysql command line + If not, import the contents of "database.sql" with phpmyadmin + or mysql command line 7. At this point visit your website again, and register your personal account. Registration errors should all be recoverable automatically. @@ -173,10 +174,10 @@ one shown, substituting for your unique paths and settings: You can generally find the location of PHP by executing "which php". If you have troubles with this section please contact your hosting provider for -assistance. The RedMatrix will not work correctly if you cannot perform this step. +assistance. RedMatrix will not work correctly if you cannot perform this step. -You should also be sure that $a->config['system']['php_path'] is set correctly, it should -look like (changing it to the correct PHP location) +You should also be sure that $a->config['system']['php_path'] is set correctly, +it should look like (changing it to the correct PHP location) $a->config['system']['php_path'] = '/usr/local/php53/bin/php'; @@ -193,20 +194,20 @@ $a->config['system']['php_path'] = '/usr/local/php53/bin/php'; "System is currently unavailable. Please try again later" ##################################################################### - Check your database settings. It usually means your database could not -be opened or accessed. If the database resides on the same machine, check that +Check your database settings. It usually means your database could not be +opened or accessed. If the database resides on the same machine, check that the database server name is the word "localhost". ##################################################################### - 500 Internal Error ##################################################################### - This could be the result of one of our Apache directives not being +This could be the result of one of our Apache directives not being supported by your version of Apache. Examine your apache server logs. Also check your file permissions. Your website and all contents must generally be world-readable. - It is likely that your web server reported the source of the problem in +It is likely that your web server reported the source of the problem in its error log files. Please review these system error logs to determine what caused the problem. Often this will need to be resolved with your hosting provider or (if self-hosted) your web server configuration. @@ -215,23 +216,23 @@ provider or (if self-hosted) your web server configuration. - 400 and 4xx "File not found" errors ##################################################################### - First check your file permissions. Your website and all contents must +First check your file permissions. Your website and all contents must generally be world-readable. - Ensure that mod-rewite is installed and working, and that your +Ensure that mod-rewite is installed and working, and that your .htaccess file is being used. To verify the latter, create a file test.out containing the word "test" in the top directory of the RedMatrix, make it world readable and point your web browser to http://yoursitenamehere.com/test.out - This file should be blocked. You should get a permission denied message. +This file should be blocked. You should get a permission denied message. - If you see the word "test" your Apache configuration is not allowing -your .htaccess file to be used (there are rules in this file to block access +If you see the word "test" your Apache configuration is not allowing your +.htaccess file to be used (there are rules in this file to block access to any file with .out at the end, as these are typically used for system logs). - Make certain the .htaccess file exists and is readable by everybody, then +Make certain the .htaccess file exists and is readable by everybody, then look for the existence of "AllowOverride None" in the Apache server configuration for your site. This will need to be changed to "AllowOverride All". @@ -244,7 +245,7 @@ likely that mod-rewrite is not installed in your web server or is not working. % a2enmod rewrite % /etc/init.d/apache2 restart - Consult your hosting provider, experts on your particular Linux +Consult your hosting provider, experts on your particular Linux distribution or (if Windows) the provider of your Apache server software if you need to change either of these and can not figure out how. There is a lot of help available on the web. Google "mod-rewrite" along with the @@ -256,7 +257,7 @@ name of your operating system distribution or Apache package. due to permissions issues: ##################################################################### - create an empty file with that name and give it world-write permission. +create an empty file with that name and give it world-write permission. For Linux: % touch .htconfig.php diff --git a/mod/events.php b/mod/events.php index 86a2286b2..513899308 100755 --- a/mod/events.php +++ b/mod/events.php @@ -12,6 +12,8 @@ function events_post(&$a) { return; $event_id = ((x($_POST,'event_id')) ? intval($_POST['event_id']) : 0); + $event_hash = ((x($_POST,'event_hash')) ? $_POST['event_hash'] : ''); + $xchan = ((x($_POST,'xchan')) ? dbesc($_POST['xchan']) : ''); $uid = local_user(); @@ -67,19 +69,22 @@ function events_post(&$a) { // and we'll waste a bunch of time responding to it. Time that // could've been spent doing something else. - if(strcmp($finish,$start) < 0) { - notice( t('Event can not end before it has started.') . EOL); - goaway($a->get_baseurl() . '/events/new'); - } $summary = escape_tags(trim($_POST['summary'])); $desc = escape_tags(trim($_POST['desc'])); $location = escape_tags(trim($_POST['location'])); $type = 'event'; + $action = ($event_hash == '') ? 'new' : "event/" . $event_hash; + $onerror_url = $a->get_baseurl() . "/events/" . $action . "?summary=$summary&description=$desc&location=$location&start=$start_text&finish=$finish_text&adjust=$adjust&nofinish=$nofinish"; + if(strcmp($finish,$start) < 0 && !$nofinish) { + notice( t('Event can not end before it has started.') . EOL); + goaway($onerror_url); + } + if((! $summary) || (! $start)) { notice( t('Event title and start time are required.') . EOL); - goaway($a->get_baseurl() . '/events/new'); + goaway($onerror_url); } $share = ((intval($_POST['share'])) ? intval($_POST['share']) : 0); @@ -450,6 +455,19 @@ function events_content(&$a) { $channel = $a->get_channel(); + // Passed parameters overrides anything found in the DB + if($mode === 'edit' || $mode === 'new') { + if(!x($orig_event)) $orig_event = array(); + // In case of an error the browser is redirected back here, with these parameters filled in with the previous values + if(x($_REQUEST,'nofinish')) $orig_event['nofinish'] = $_REQUEST['nofinish']; + if(x($_REQUEST,'adjust')) $orig_event['adjust'] = $_REQUEST['adjust']; + if(x($_REQUEST,'summary')) $orig_event['summary'] = $_REQUEST['summary']; + if(x($_REQUEST,'description')) $orig_event['description'] = $_REQUEST['description']; + if(x($_REQUEST,'location')) $orig_event['location'] = $_REQUEST['location']; + if(x($_REQUEST,'start')) $orig_event['start'] = $_REQUEST['start']; + if(x($_REQUEST,'finish')) $orig_event['finish'] = $_REQUEST['finish']; + } + if($mode === 'edit' || $mode === 'new') { $n_checked = ((x($orig_event) && $orig_event['nofinish']) ? ' checked="checked" ' : ''); @@ -537,6 +555,7 @@ function events_content(&$a) { '$eid' => $eid, '$xchan' => $event_xchan, '$mid' => $mid, + '$event_hash' => $event_id, '$title' => t('Event details'), '$desc' => t('Starting date and Title are required.'), @@ -548,11 +567,11 @@ function events_content(&$a) { '$ftext' => $ftext, '$ModalCANCEL' => t('Cancel'), '$ModalOK' => t('OK'), - '$s_dsel' => datetimesel($f,mktime(),mktime(0,0,0,0,0,$syear+5),mktime(),'start_text'), + '$s_dsel' => datetimesel($f,mktime(),mktime(0,0,0,0,0,$syear+5),mktime($shour,$sminute,$ssecond,$smonth,$sday,$syear),'start_text'), '$n_text' => t('Finish date/time is not known or not relevant'), '$n_checked' => $n_checked, '$f_text' => t('Event Finishes:'), - '$f_dsel' => datetimesel($f,mktime(),mktime(0,0,0,0,0,$fyear+5),mktime(),'finish_text',true,true,'start_text'), + '$f_dsel' => datetimesel($f,mktime(),mktime(0,0,0,0,0,$fyear+5),mktime($fhour,$fminute,$fsecond,$fmonth,$fday,$fyear),'finish_text',true,true,'start_text'), '$a_text' => t('Adjust for viewer timezone'), '$a_checked' => $a_checked, '$d_text' => t('Description:'), diff --git a/view/tpl/event_form.tpl b/view/tpl/event_form.tpl index ade404125..a4717415e 100755 --- a/view/tpl/event_form.tpl +++ b/view/tpl/event_form.tpl @@ -9,6 +9,7 @@ <form action="{{$post}}" method="post" > <input type="hidden" name="event_id" value="{{$eid}}" /> +<input type="hidden" name="event_hash" value="{{$event_hash}}" /> <input type="hidden" name="xchan" value="{{$xchan}}" /> <input type="hidden" name="mid" value="{{$mid}}" /> |