0 Members and 1 Guest are viewing this topic.

*

NomadMike

  • *
  • 6
  • osDate Version: osDate v2.7
New installation a few questions on setting my site up
« on: May 28, 2017, 04:39:25 AM »
Hi, I tried out OSDate a few years ago, its good to see it is still going and has had some updates. I have run a fresh install the site is working fine I have a few questions if I click the Chat link under admin I do not see any options do I need to add my own chat script? I did not see an option under the plugins link to install a chat system. I have downloaded FreiChat will this work with OSDate?

How can I change the Welcome to osDateEvo I looked at the content section but could not find the welcome section or is this hard coded?

I notice I can use a forum for the website can anyone recommend the best one to use?

thanks

Mike


*

Pharg

  • *****
  • 3,125
    • OsDateFourm
  • osDate Version: osDateEvo v1.3
Re: New installation a few questions on setting my site up
« Reply #1 on: May 28, 2017, 07:53:22 AM »
Hi Mike,

Thanks and yes you have to add your own chat to osDateEvo.

The Welcome to osDateEvo has to be changed in the language files, all changes then must be reloaded in the admin under language management for the changes to show and do the necessary changes in the database.

Freichat works but has to modified to work with osDateEvo, I attached the modded version below, please follow the instructions.

You can also use Cometchat basic and it will cost about 43 dollars.

For the forum it's best to use the version I have attached, you might have to find a responsive theme for it though.
« Last Edit: May 28, 2017, 08:01:39 AM by Pharg »
Regards,
Pharg ( Phill )

REMEMBER: ALWAYS BACKUP BEFORE YOU MAKE ANY CHANGES!!

osDateEvo v1.3 | PHP: 5.3.42 & PHP: 7.1.15 | MySQL: 5.5.35

*

NomadMike

  • *
  • 6
  • osDate Version: osDate v2.7
Re: New installation a few questions on setting my site up
« Reply #2 on: May 28, 2017, 09:37:14 AM »
Thanks for the reply I have bought the FreshDate template which was well worth the $11.99, will that template work with the files you provided?

I am also looking at a stripe payment module as the payment modules are based on Oscommerce I am going to see if I can create a payment plugin for the stripe payment gateway, it's been a while since I have done any php coding so it might take me a while.


*

NomadMike

  • *
  • 6
  • osDate Version: osDate v2.7
Re: New installation a few questions on setting my site up
« Reply #3 on: May 28, 2017, 11:12:43 AM »
Hi I have tried to install Freichat it loads and shows in the footer however it does not display a username only guest-oui

after I ran the install I coppied your hardcoded syntax after the database connection settings - in the install window step 3 it shows me some code and tells me to edit it - it is not editable ?

this is the code

Code: [Select]
if(USER_IS_LOGGED_IN)
{
    $ses = LOGGED_IN_USERID; //tell freichat the userid of the current user

    setcookie("freichat_user", "LOGGED_IN", time()+3600, "/"); // *do not change -> freichat code
}
else {
    $ses = null; //tell freichat that the current user is a guest

    setcookie("freichat_user", null, time()+3600, "/"); // *do not change -> freichat code
}

where am I supposed to change this

*

Pharg

  • *****
  • 3,125
    • OsDateFourm
  • osDate Version: osDateEvo v1.3
Re: New installation a few questions on setting my site up
« Reply #4 on: May 28, 2017, 10:13:30 PM »
Hi Mike,

That code goes into the index.php temporary until the script is installed then once it is, it gets replaced by the index.php I gave you.
You can skip these code changes as I have already done them in the index.php and the index_header.tpl files.

All you want for now is the freichat database installed into the osdate database.
Then upload the 2 index files given.
Regards,
Pharg ( Phill )

REMEMBER: ALWAYS BACKUP BEFORE YOU MAKE ANY CHANGES!!

osDateEvo v1.3 | PHP: 5.3.42 & PHP: 7.1.15 | MySQL: 5.5.35

*

NomadMike

  • *
  • 6
  • osDate Version: osDate v2.7
Re: New installation a few questions on setting my site up
« Reply #5 on: May 29, 2017, 12:45:20 PM »
Ok I ran the install to get the db tables setup - when I log in I only see guest - when I log out I see my username? seems like it is working backwards lol

this is the code I have in index.php

Code: [Select]
/* FreiChat STARTS HERE */

if($Username_And_Password_Match)
{
   $_SESSION['UserId'] = $users['id']; // Modify to suit your requirements


$ses = null; // Return null if user is not logged in
 
if(isset($_SESSION['UserId']))
{
  if($_SESSION['UserId'] != null) // Here null is guest
  {
   $ses=$_SESSION['UserId']; //LOOK, now userid will be passed to FreiChat
   
  }
}
}
if(!function_exists("freichatx_get_hash"))
{
function freichatx_get_hash(){
       if(is_file("http://*****.tk/freichat/hardcode.php")){

               require "http://*****.tk/freichat/hardcode.php";

               $temp_id =  $ses . $uid;

               return md5($temp_id);

       }
       else
       {
               echo "<script>alert('module freichatx says: hardcode.php file not found!')</script>";
       }

       return 0;
}
}
/* FreiChat ENDS HERE */

this is me logged out
http://prntscr.com/fdd2px

and when I login
http://prntscr.com/fdd35f

backwards?

*

NomadMike

  • *
  • 6
  • osDate Version: osDate v2.7
Re: New installation a few questions on setting my site up
« Reply #6 on: May 29, 2017, 12:48:04 PM »
Also, I notice you have removed the set cookie in your code any reason for this?

the code in the installer

Code: [Select]
$ses = LOGGED_IN_USERID; //tell freichat the userid of the current user

    setcookie("freichat_user", "LOGGED_IN", time()+3600, "/"); // *do not change -> freichat code
}
else {
    $ses = null; //tell freichat that the current user is a guest

    setcookie("freichat_user", null, time()+3600, "/"); // *do not change -> freichat code


*

Pharg

  • *****
  • 3,125
    • OsDateFourm
  • osDate Version: osDateEvo v1.3
Re: New installation a few questions on setting my site up
« Reply #7 on: May 29, 2017, 10:08:46 PM »
Hi Mike,

You don't need to have the cookie code but if you want to use it, it should be fine.

Make sure you also setup in the admin area all the settings, setting it to members only doesn't work. Play around with the setting until your happy with it's setup, It doesn't work 100% all the time sorry.

You can go to the Freichat forum for further help as they are the ones that modded this for me.

Also I noticed the template is not the default one, so I am not sure that the index_header.tpl I gave you will work, all you need from that, is the Freichat code put in the FreshDate template.

I sent you some code changes in the reply of your PM.
« Last Edit: May 29, 2017, 11:44:40 PM by Pharg »
Regards,
Pharg ( Phill )

REMEMBER: ALWAYS BACKUP BEFORE YOU MAKE ANY CHANGES!!

osDateEvo v1.3 | PHP: 5.3.42 & PHP: 7.1.15 | MySQL: 5.5.35