Wednesday, September 10, 2008
Speech Synthesizer Using Java TTS Library
2- Unzip the files (mainly you will need only bin folder).
3- Add freetts.ja in lib directory into your classpath (or you can add them in Eclipse)
4- Write you Java program that will speak :)
Tuesday, September 2, 2008
Steps to Use mod_proxy_ajp to integrate Apache and Tomcat
mod_proxy_ajp is a connector to connect Tomcat and Apache Httpd, it is activated from Apache Httpd. When it is activated the requests will be sent using AJP protocol into Tomcat and recieve results back.To test if the following steps works type the url that contains the folder you want to send its requests into Tomcat and the url has to change to the address given in the configuration (ajp).
Steps:
1.Enable the AJP connector for one or more tomcat installations by editing TOMCAT_HOME/conf/server.xml and uncommenting the AJP connector included with the default distribution:
2.uncomment the "LoadModule proxy_module ...." and "LoadModule proxy_ajp_module ...." in the file APACHE_HTTPD_HOME/conf/httpd.conf
3. Add the following lines
#The client makes ordinary requests for content in the name-space of the reverse proxy. The reverse proxy then decides where to send those requests, and returns the content as if it was itself the origin. a reverse proxy (using the ProxyPass directive with ProxyRequests Off)
<IfModule proxy_module>
ProxyRequests Off
#Activate reverse proxy
<Proxy *>
Order Deny,Allow
Allow from all
</Proxy>
ProxyPass /OATS ajp://localhost:8009/OATSMoodle
ProxyPassReverse /OATS ajp://localhost:8009/OATSMoodle
#OATS is which folder we will access in Apache in order to be passed into Tomcat address
Which is (OATSMoodle) in this case. When you type URL (or send requests) that contains OATS it will be send into "localhost:8080/OATSMoodle" which is the folder in Tomcat.
</IfModule>
Thursday, August 7, 2008
Adding Perl CGI support into Apache server
Modify the conf/httpd.con file in Apache
Add to the options in
AcceptPathInfo On
Options FollowSymLinks +ExecCGI
Check that the file has
AddHandler cgi-script .cgi .pl
At the beginning of your program point where is your Perl executable are:
#!c:/program files/perl/bin/perl.exe
Just write your program and save it in .pl extension and access the file using
http://localhost/perlTest/hello.pl
Sunday, August 3, 2008
Connecting Tomcat & Apache
Go the Tomcat Connectors (mod_jk) Downloads
mod_jk is a module that passes specific requests from Apache to Tomcat. Tomcat processes a request, and sends the response back through Apache.
Apache Tomcat JK 1.2.26 for WIN32
- mod_jk-1.2.26-apache-2.2.4.so is for Apache 2.2, and works with Apache 2.2.4 and later. Rename to mod_jk.so before putting it in your Apache2.2/modules directory.
- tells Apache that the module exists and where to find it using a LoadModule directive, in conf/httpd.conf file.
- The JkWorkersFile should point to the location of the file that specifies how mod_jk should connect to the Tomcat service and interact with the various worker processes created by Tomcat. tell Apache how to identify which Tomcat process to communicate and forward the request.
JkWorkersFile /usr/local/apps/jakarta-tomcat-4/conf/workers.properties
JkLogFile /usr/local/apache/logs/mod_jk.log
JkLogLevel info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "The file contains
workers.tomcat_home=/usr/local/apps/jakarta-tomcat-4
workers.java_home=/usr/java1.4.1
ps=/
worker.list=ajp13
worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
Forwarding Requests
The final step is to tell Apache which files should be assigned to Tomcat for processing and which of the workers to direct the request to. You do this using the JkMount directive, which effectively mounts a Tomcat worker process to a given file specification. For example, to redirect all requests for files ending in .jsp on this server to the worker identified as ajp13, you would use:
JkMount /*.jsp ajp13 |
JkMount /* ajp13If the error was generated by Tomcat, then you need to check the Tomcat logs in the main Tomcat installation directory. It probably means either there is an error in your JSP or a class on which it relies or there is a problem with accessing the file in question. Because requests are forwarded to Tomcat immediately, a missing file will be reported by Tomcat, not Apache.
Testing it Out
To test out your installation, copy a suitable JSP or servlet into
your Web server directory and then try accessing it from a browser.
Remember that you must have both Tomcat and Apache running. Assuming
everything is working OK then you should get the desired result. If
there's an error, you'll need to check one of the various log files for
more information. To help you determine which one, look at the error
message reported in the browser.
If it's an error generated by Apache, check the Apache logs and the mod_jk logs. If the error is reported in the mod_jk log, then it probably points to a problem with the configuration somewhere.
If you get an Internal Server Error from Apache, then check whether Tomcat is running before digging any deeper.
Sunday, July 27, 2008
Ideas For Research
Ideas For Research
Create Website have all information about making the internet with Arabic contents accessible for everyone.
Accessibility for online museums
Voice guided Java 2 micro edition can be used to add programs to cell phones.
Apache Lenya : Open Source content managment system which output is accessible.
Dot Learn is and open source LMS
to make Java choose any natural language use (i18N).
www.esstt.rnu.tn/utic (webSign at university of Tunis)
How to setup your online course to fit your disability best.
Convert word,PDF into MP3 (www.read thewords.com)
Working Group in W3C, 4 hours per week
Adding rules for audio to read mathematical contents in a more meaningful way:
A^T (A transpose)
V^--> (vector V)
Firebug Ally accessibility extension
SUN open accessibility framework
it is hard for novice developer to remember all W3C, WCAG and section 508.
From the presentation of equation you can know what contents it presents and vice versa.
providing substitution within mathematical expression (replace complex sub-expressions with meaningful phrases) to give an overview of the equation.
Notes For My work
We need to have audio description while we move through different interfaces.
in human computer interaction Nielsen approach to evaluate user interface is the most useful one.
To identify cognitive learning styles use Felming and Mellis model.
Highlight has to start and end in space
Use ARIA for iframe to notify the user about the window when it appears
Ideas related to Data picker may be used to knwo how to make my iframe accessible.
To add web service to my work use Apache Axis
Friday, May 30, 2008
Latex in Windows
- download Tex distribution (usually MikTex (http://www.miktex.org/) )
- download and install the LeD latex editor
Using command line
- create using any text editor and save the file with extension (.tex)
- to create the div file that can be viewed use the command (latex file.tex)
- to convert div file into pdf (dvipdfm file.div)
- for Windows use the software MikTex
How to generate PDF file
if you want to convert the latex into pdf (in Miketex) it will not recognize the .eps pictures. You can press DVI-> PDF which will convert the file into pdf without the need to change all the picture files into png extension.
Using Led Editor
You will see the pdf result immediately on the right opf the screen, also you can click on the pdf to reach to specific pieces on the tex file.
Just press the green button (Latex Compilation)
How to use references file (bib) in LED editor?
Getting current Latex document to use your .bib file is not actually very difficult. At the end of your Latex file (that is, after the content, but before \end{document}, you need to place the following commands:
\bibliographystyle{plain}
\bibliography{sample}
where sample is sample.bib
Now in Led editor you never complie the .bib file, just the .tex file.
Open up the .tex file and compile it using Latex then compile it using Bibtex
You might then have to compile it again using Latex to finish the process.
Printing the URL Field
In order to printout URL’s, you can make use of the howpublished field. Try this: howpublished = {\url{http://texblog.wordpress.com}},
You will have to add the url-package to your tex-document: \usepackage{url}.
How to keep Capitalization in the title field?
surrounded by extra brackets to preserve the capitalization.without changing the way it appears in the bibliography. by adding extra curly brackets around some characters
How to Fix the problem of figures not shown in LED DVI viewer?
Check the gsdll32.dll path in LED->menu->Configuration->options->Application->DVI viewer->GSDL32.dll directory. Make sure that the path points to the right GSView bin directory.
Wrapping Figures
Although not normally the case in academic writing, an author may prefer that some floats do not break the flow of text, but instead allow text to wrap around it. (Obviously, this effect only looks decent when the figure in question is significantly narrower than the text width.) The package wrapfig was developed for this very task.
To use wrapfig, you must first add \usepackage{wrapfig} to the preamble. This then gives you access to the \begin{wrapfigure}{alignment}{width} command. Alignment can be either l for left, or r for right. The width is obviously the width of the figure. An example:
\begin{wrapfigure}{r}{40mm}
\begin{center}
\includegraphics{toucan.eps}
\end{center}
\caption{The Toucan}
\end{wrapfigure}
Make a folder tree myowntexmf\tex\latex\mystyles
Put the file in mystyles and then add myowntexmf as a new local root
in miktex settings.
Errors
- "Misplaced alignment tab character &".
- In LaTeX, the "&" character is used for tabbing (alignment) in certain environments, but it is not a legal character on its own; that is what the first line of the error message above is saying - that the character "&" is being used somewhere it shouldn't. Click "Go To Error" to go to the place where the compiler thinks there is an error in the editing window.
Tuesday, May 20, 2008
Increase Heap in Eclipse
Project -> Properties->Run/Debug setting -> Edit ->Arguments ->VM arguments (-Xmx256M)
From command line
java -Xms32m -Xmx128m
In Tomcat
Edit bin/Catalania.bat add -Xmx256m to JAVA_OPTS
Sunday, May 18, 2008
Eclipse + Servlet +Tomcat
For Tomcat version 6.0 and Eclipse version 3.3.0
You have to manually import context.xml from location
C:\Tomcat-6.0\conf\
to
MyWorkspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\conf
and then changes to
Context reloadable="true"
and
privileged="true"
Now how to run servlets on Eclipse:
1- New "Dynamic web Project"
2- new -> Target run time -> choose tomcat server and its main folder as the source path.
3- R-click on the project -> new ->servlet (no need to have package name)
4- R-click on the servelt Java file and Run-as server
For the servlet to work the class file has to be in
/tomcat/webapps/project/web-inf/classes
and the HTML file (with FORM METHOD=GET ACTION="Hello" , where Hello is the servlet name)can be in
/tomcat/webapps/project/
You can have multiple servlets defined inside web.xml, each one will be inside the servet tag.
Saturday, May 17, 2008
Servlets
- Servlets are simply
.class
files, i.e., compiled.java
files. - Servlet files are stored in the
subdirectory of the main web application directory. In this case theWEB-INF/classes
.class
files for theexamples
web app is stored in .%TOMCAT_HOME%/webapps/examples/WEB-INF/classes
- So when the user requests
http://localhost:8080/examples/servlet/HelloWorldExample
Tomcat runs%TOMCAT_HOME%/webapps/examples/WEB-INF/classes/HelloWorldExample.class
- Create a folder inside webppas of Tomcat server (star, for example)
- "\WEB-INF\classes" is the folder to keep Servlet class files
- 'web.xml' is saved in the '/WEB-INF' folder
- Compile command
The url to access the servlet , after starting Tomcat server
http://localhost:8080/star/TestServlet
------------------------------------------------
1- must run Tomcat server then try http://localhost:8080 to verify it works
2- There is a specific structure for the files
3-assign your servlet class to a package, for example at the beginning of the Java file
package org.oats;
4- Need to tell were the servlets resides (the path classes) using web.xml
which is saved in
Finally, again in the web.xml file, add:
That says "When you see the URL /Ontology, call the Servlet name "Ontology",
which is mapped to the 'org.oats.OntologyServlet' class".
5- the two main methods to implement in servlets are doGet and doPost
Monday, May 12, 2008
Mod Python (using python in the web)
ModPython
How to install:
1-Download binaries for windows
2-run the installer (must have installed Python and Apache server , with same versions compatabile with the version of modPython)
3- Choose place of where Python is installed
4- Add the line into conf/httpd.conf
LoadModule python_module modules/mod_python.so
5- Add the following as a new Directory tags in the file conf/httpd.conf (Directory is a tag < >)
Directory "E:\moodle\moodle\PythonTest"
AddHandler mod_python .py
PythonHandler mptest
PythonDebug On
/Directory
Now to test it create a file with .py inside the root of apache, it will execute the function with the name handler.
To Work With forms
PythonHandler mod_python.publisher
It will pass the form into the the .py file into the function name index(), with the same names of the fields.
Thursday, May 8, 2008
How to use protege OWL API in Eclipse
2-Goto Project->Properties-> Java Build Paths
Libraries tab, click add external JARS and go
inside Protege directory ->select all jar files.
inside Protege directory ->Plugins inside (edu.stanford.smi.protegex.owl) select all jar files.
Also
Select protege.api from /protege/
in Java code
import edu.stanford.smi.protegex.owl.ProtegeOWL;
import edu.stanford.smi.protegex.owl.model.*;
Friday, April 18, 2008
Tomcat With Eclipse
2- Windows -> Preferences -> Java -> Installed JRE (must be the JDK folder)
3- Download “Sysdeo Tomcat Lanucher” and unzip the folder into “Eclipse\Plugins”
4- In the command line “eclipse –clean”
5- Window -> Preference -> Tomcat (Select version and home folder of Tomcat)
Thursday, April 17, 2008
Installing Tomcat
2. Set the JAVA_HOME Variable
Next, you must set the JAVA_HOME environment variable to tell Tomcat where to find Java. Failing to properly set this variable prevents Tomcat from compiling JSP pages. This variable should list the base JDK installation directory, not the bin subdirectory. For example, on almost any version of Windows, if you use JDK 1.5_08, you might put the following line in your C:\autoexec.bat file.
set JAVA_HOME=C:\Program Files\Java\jdk1.5.0_08
On Windows XP, you could also go to the Start menu, select Control Panel, choose System, click on the Advanced tab, press the Environment Variables button at the bottom, and enter the JAVA_HOME variable and value directly. On Windows 2000 and NT, you do Start, Settings, Control Panel, System, then Environment. However, you can use C:\autoexec.bat on those versions of Windows also (unless a system administrator h as set your PC to ignore it).
3. Set Your CLASSPATH
Since servlets and JSP are not part of the Java 2 platform, standard edition, you have to identify the servlet classes to the compiler. The server already knows about the servlet classes, but the compiler (i.e., javac) you use for development probably doesn't. So, if you don't set your CLASSPATH (either via an environment variable, an operating system setting, or an IDE setting), attempts to compile servlets, tag libraries, filters, Web app listeners, or other classes that use the servlet and JSP APIs will fail with error messages about unknown classes. Here are the standard Tomcat locations:
* install_dir/common/lib/servlet-api.jar
* install_dir/common/lib/jsp-api.jar
You need to include both files in your CLASSPATH.
Now, in addition to the servlet JAR file, you also need to put your development directory in the CLASSPATH. Although this is not necessary for simple packageless servlets, once you gain experience you will almost certainly use packages. Compiling a file that is in a package and that uses another class in a user-defined package requires the CLASSPATH to include the directory that is at the top of the package hierarchy. In this case, that's the development directory I just discussed. Forgetting this setting is perhaps the most common mistake made by beginning servlet programmers!
Finally, you should include "." (the current directory) in the CLASSPATH. Otherwise, you will only be able to compile packageless classes that are in the top-level development directory.
Here are two representative methods of setting the CLASSPATH. They assume that your development directory is C:\Servlets+JSP. Replace install_dir with the actual Tomcat installation path (e.g., C:\apache-tomcat-6.0.10). Also, be sure to use the appropriate case for the filenames, and enclose your pathnames in double quotes if they contain spaces.
Any Windows Version from Windows 98/Me Onward. Use the autoexec.bat file.
* Sample code: (Note that this all goes on one line with no spaces--it is broken here only for readability.)
set CLASSPATH=.;
C:\Servlets+JSP;
install_dir\common\lib\servlet-api.jar;
install_dir\common\lib\jsp-api.jar
* Sample file to download and modify: autoexec.bat
Note that these examples represent only one approach for setting the CLASSPATH. Many Java integrated development environments have global or project-specific settings that accomplish the same result. But these settings are totally IDE-specific and won't be discussed here. Another alternative is to make a .bat file or ant build script whereby -classpath ... is automatically appended onto calls to javac.
Windows NT/2000/XP. You could use the autoexec.bat file as above, or you can use system settings. On WinXP, go to the Start menu and select Control Panel, then System, then the Advanced tab, then the Environment Variables button. On Win2K/WinNT, go to the Start menu and select Settings, then Control Panel, then System, then Environment. Either way, enter the CLASSPATH value from the previous bullet.
Autoexec.bat
set PATH="C:\Program Files\Java\jdk1.5.0_08\bin";%PATH%
set JAVA_HOME=C:\Program Files\Java\jdk1.5.0_08
set CLASSPATH=.;C:\apache-tomcat-6.0.10\lib\servlet-api.jar;C:\apache-tomcat-6.0.10\lib\jsp-api.jar;C:\apache-tomcat-6.0.10\lib\el-api.jar;C:\Servlets+JSP;..;..\..
Tuesday, April 15, 2008
How to Import .SQL Dump File into MySQL
1. Open the MySQL Command Line Client and type in your password, and press Enter to login. See Figure 1.
2. Change to the database you want to use for importing the .sql file data into. Do this by typing
USE your_database_name
and press Enter. See Figure 2.
For example the full line would look like: mysql> USE myTestDatabase
3. Now locate the .sql file you want to execute. For instance if the file is located in the main local C: drive directory and the .sql script file name is currentSqlTable.sql, (See Figure 3) you would type the following:
\. C:\currentSqlTable.sql
and press Enter to execute the sql script file.
For example, the full line would look like: mysql> \. C:\ currentSqlTable.sql
Note: You can use either the source or \. command to execute a SQL script file. For instance:
mysql> source file_name
mysql> \. file_name
Saturday, April 12, 2008
Ideas about tagging
What happened when the user click on the tag button (delicious) on the tool bar of the explorer, we need to do similar thing from a link from inside the web page. This type of tagging will be only for the whole web page, but in order to tag specific parts of the web page we need something to specify that (keystroke when we reach specific part of the page, new menu item when mouse is clicked ). Remember that whatever you tag it will be one of two things (whole page, specific anchor link in the page).
Monday, March 10, 2008
Tag Cloud Ideas
how many tags associated with each tag is presented or we can use a text that describe how popular is that tag.
we can just use classes to define the different sizes (we can identify there sizes explicitly using the class attribute).
use of an ordered list as the tag cloud structure, or play with voice volume when the font size changes.
screen reader user doesn't get when a size "step" has changed
sort by frequency is another solution.
Friday, March 7, 2008
Accessible Tags and Tag Clouds
To make tag cloud accessible we could make the screen reader read the tags according to the font size (not in the alphabetical order). Also it is important to provide the users with tags and related tags in an accessible way.
range of class names from not-popular through ultra-popular
- 44 photos are tagged with 125 Shaftesbury Avenue
- 2 photos are tagged with airline food
- 344 photos are tagged with austin
- 12 photos are tagged with bad joke
- 52 photos are tagged with brighton
- 12 photos are tagged with cowboy hat
- 67 photos are tagged with fireworks
- 2 photos are tagged with fozziebear
- 85 photos are tagged with ironbridge
- 12 photos are tagged with jukebox
- 72 photos are tagged with leave a message
- 26 photos are tagged with lego
- 151 photos are tagged with London
- 25 photos are tagged with microformats
- 107 photos are tagged with Pub Standards
- 355 photos are tagged with San Francisco
- 194 photos are tagged with sxsw
- 13 photos are tagged with The hair of Christian Heilmann
- 1 photo is tagged with The reflection of the hair of Christian Heilmann
- 2 photos are tagged with yaarrrrrrrrrrrrrrrrr
Monday, February 18, 2008
Thursday, February 14, 2008
Monday, February 4, 2008
What Are Screening Techniques?
http://www.uiaccess.com/accessucd/screening.html
Thursday, January 31, 2008
ELGG, Social Networking
http://www.elgg.org/
Plugins
Most plugins work in one of two ways, they either provide a lib.php filled with common functions and some scripts with standard names, or they subclass a proto-plugin and override a few method functions to achieve their goals.
The best way to learn is to pick an example from the core code that is similar to what you want to do and start playing with it. There are also some template plugins to help get you started.
Wednesday, January 30, 2008
Firefox Web Developer Extension
http://chrispederick.com/work/web-developer/
Fluid, improve accessibility of e-learning
What is Fluid?
Fluid is a worldwide collaborative project to help improve the usability and accessibility of community open source projects with a focus on academic software for universities. We are developing and will freely distribute a library of sharable customizable user interfaces designed to improve the user experience of web applications.
http://fluidproject.org/
Accessibilityy Evaluation
For manual tests I used firefox web developer tool and fangs extension, as well as opera browser and screen reader jaws for windows.
Monday, January 28, 2008
Ideas
Having all the alt text of the images,acronym and video captions in a database of the web site and when we reuse the images we get the same alt text from that database.
wizard that will create a user profile in the database for each user, and it will be used to customize the settings of the system each time the user log into the system.
Screen reader
JAWS, some are using Blindows with Webformator and Thunder.