This is the community forum. For a developer response use the Client Area.
Follow us on Facebook, Twitter and YouTube!

Webcalender + Commentics,And Example Change of Character Code
#1

WebCalendar is a PHP-based calendar application,available under the GNU General Public License, version 2.
http://www.k5n.us/webcalendar.php

Code:
#########################################
# Webcalender1.2.3 + Commentics 1.6
#
# Easy
#
###### Webcalender Script######################
##--- OPEN ------------------
#
view_entry.php

#
#####----- FIND -------------
# first Line
<?php
/* $Id: view_entry.php,v 1.174.2.13 2010/08/15 03:27:44 cknudsen Exp $
*
* Description:
* Presents page to view an event with links to edit, delete
* confirm, copy, add event
#
##---- Before Add -----------
#
<?php
     session_start();
     ob_start();
?>
#
#### ---FIND ---------
# if ( Doc::commentsEnabled () )... Comment OUT
# About Line 840

if ( Doc::commentsEnabled () ) {
  echo '

#
## -- Before Add ---------------
#

/*****

#
####--- Find ---------------
#

  $num_app = $num_rej = $num_wait = 0;

  echo '</td>
      </tr>';
}

#
###--- After Add ----------------
#

******/


#
####------ FIND --.example..---------
#
# About Line980
if ( $can_add_comment && $event_status != 'D' ) {
  $addCommentStr = translate ( 'Add Comment' );
  echo '
      <li><a title="' . $addCommentStr
   . '" class="nav" href="docadd.php?type=C&amp;id=' . $id
   . $u_url . '">' . $addCommentStr
   . '</a></li>';
}
#
###--- Replace With -------------------
#
/**** Comment Out ******
if ( $can_add_comment && $event_status != 'D' ) {
  $addCommentStr = translate ( 'Add Comment' );
  echo '
      <li><a title="' . $addCommentStr
   . '" class="nav" href="docadd.php?type=C&amp;id=' . $id
   . $u_url . '">' . $addCommentStr
   . '</a></li>';
}
*****/
echo '</ul>';
$page_id = "$id"; #
$reference = "$name"; #
$path_to_comments_folder = "comments/";
define ('IN_COMMENTICS', 'true');
require $path_to_comments_folder . "includes/commentics.php";
echo '<ul>';

#
######--- OPEN ----------------
#
includes/init.php
#
## ------ FIND ----------------
#
  </head>
  <body'
  // Determine the page direction (left-to-right or right-to-left).
#
## ------ Before Add ----------------
#
    <link rel="stylesheet" type="text/css" href="comments/css/stylesheet.css"/>
#
################################################################
################################################################
sample ,Sorry .. Japanese Language Site..
Integration sample
This sample isn't Uicode(utf-8) , Charactet Code UTF8 --> EUC-JP.
Code:
## Example of Conversion in Caracter code ,
## UTF8 --> EUC-JP.
1: Caracter contained in file 'comments/** All File'
   utf-8  ----->EUC-JP
   UTF-8  ----->EUC-JP

2: comments/includes/db/connect.php

  mysql_set_charset('utf8'); --> mysql_set_charset('ujis');

  mysql_query("SET NAMES 'UTF8'");  --> mysql_query("SET NAMES 'ujis'");

3: All Language File Save As EUC-JP
  comments/includes/language/***/*.txt
  comments/includes/emails/***/user/***.txt
  comments/includes/emails/***/admin/****.txt
  comments/includes/words/**.txt
  comments/includes/template/**.txt


---------------------------------------------------
Commentics's Japanese Commentary Site
http://commentics.bbfriend.net/
*Sorry...I am not good at English.
---------------------------------------------------
Reply


Possibly Related Threads…
Thread / Author Replies Views Last Post
Last Post by kbadmin
28-May-2019, 07:16 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)