Creation Zone

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Monday, 27 July 2009

Instructions to Create a Facebook Application

Posted on 11:04 by Unknown
Here is a quick HOW-To document with step-by-step instructions to create a simple Facebook application.

  1. Create an account with Facebook at facebook.com
  2. To create an application in Facebook, go to Facebook Developers web site
  3. Click on Set Up New Application.
  4. Name the Appliaction and click on save changes.
  5. Enter a brief description for the application.
  6. On the left side of the page click on Canvas.
  7. Fill the application name in Canvas Page URL field.
  8. Fill the Canvas Callback URL field.

    Canvas Callback URL is the address of the website where the appliaction is hosted.
    For example if the appliaction is hosted on a website www.xyz.com, then the Canvas Callback URL address will be http://www.xyz.com/your_application.

  9. Click on save changes.
  10. A summary of the application is shown at this point.
  11. Sample code is shown at the bottom of this page. Click on the sample code.
  12. Download and unzip the tar.gz file.

    In the footprints folder, you will find a sample Facebook application with the file name index.php

  13. Facebook appliaction can be developed in JavaScript, PHP or HTML.

    For more details about the langauges in which the application can be developed, check Facebook Developers web site.

  14. Create your Facebook application and host it on any web site of your choice. Be aware that Facebook does not host the actual application - so you are on your own in finding a hosting site to deploy your Facebook application.

  15. You can test the application from the Canvas Page URL address.

    The url will be in the format http://apps.facebook.com/appliaction_name/


Few Caveats:

If the application is developed in JavaScript, note that all the functions may not work as expected in Facebook. For example, to set the value of 5 to a text box, the following is the code in JavaScript:

var k = 5;
document.getElementById("someid").value = k;


The above code may not work in Facebook application. The following modified code works in Facebook:
var k = 5;
document.getElementById("someid").setValue(k);


To see all the Facebook equivalent functions for the JavaScript functions, check the FBJS wiki page.

If you encounter the error, FBML Error : illegal tag "body" under "fb:canvas", remove the <body> tag from the HTML application. When Facebook parses the appliaction, it addes the <body> tag automatically.

The code shown below is ready to be used as an example Facebook application. This a very basic calculator with limited functionality.

To test how this example code works, visit the following URL:
http://apps.facebook.com/basic_calc

Sample Facebook Application : Simple Calculator


<html>

<head>
<style type = "text/css">
input {
width : 30px;
height: 30px;
font-size: 1.2em;
color: red;
}
</style>

<script language="JavaScript">
var num2 = 0 , num1=0;

function Assign(myvalue)
{
var button_value , Key = 0;
button_value = myvalue.getValue();

switch(button_value)
{
case '+':
case '-':
case '*':
case '/':
case '%':
{
key = button_value;
num1 = num2;
num2 = 0;
break;
}

case '=':
{
if (key == '+')
{
Sum(num1,num2);
}

if (key == '-')
{
Subtraction(num1,num2);
}

if (key == '*')
{
Product(num1,num2);
}

if (key == '/')
{
Reminder(num1,num2);
}

if (key == '%')
{
Modulo(num1,num2);
}
break;
}

case '+/-':
{
num2 = num2 * (-1);
document.getElementById("output").setValue(num2);
break;
}

default:
{
button_value = parseInt(button_value);
combine(button_value);
break;
}
}
}

function combine(input)
{
num2 = (num2 * 10) + input;
document.getElementById("output").setValue(num2);
}

function Cancel()
{
num2 = 0;
num1 = 0;
document.getElementById("output").setValue(num2);
}

function Sum(val1,val2)
{
var result;
result = val1+val2;
document.getElementById("output").setValue(result);
num2 = 0;
num1 = 0;
}

function Subtraction(val1,val2)
{
var result;
result = val1-val2;
document.getElementById("output").setValue(result);
num2 = 0;
num1 = 0;
}

function Product(val1,val2)
{
var result;
result = val1*val2;
document.getElementById("output").setValue(result);
num2 = 0;
num1 = 0;
}

function Reminder(val1,val2)
{
var result;
result = val1/val2;
document.getElementById("output").setValue(result);
num2 = 0;
num1 = 0;
}

function Modulo(val1,val2)
{
var result;
result = val1%val2;
document.getElementById("output").setValue(result);
num2 = 0;
num1 = 0;
}

</script>

<title>Very Basic Calculator</title>
</head>

<form>

<table border="1" bgcolor = "#CDCDCD">

<tr>
<td colspan="6"><input id ="output" type="text" name="result" value="0" style="width: 169px; height: 30px; color:blue;" readonly = "readonly"/></td>
</tr>

<tr>
<td><input type="button" name="one" value="1" onclick = "Assign(this)"/></td>
<td><input type="button" name="two" value="2" onclick = "Assign(this)"/></td>
<td><input type="button" name="three" value="3" onclick = "Assign(this)"/>
<td><input type="button" name="add" value="+" onclick = "Assign(this)"/></td>
<td rowspan="2"><input type="button" name="clear" style = "height : 64px;" value="C" onclick = "Cancel()"/></td>
</tr>

<tr>
<td><input type="button" name="four" value="4" onclick = "Assign(this)"/></td>
<td><input type="button" name="five" value="5" onclick = "Assign(this)"/></td>
<td><input type="button" name="six" value="6" onclick = "Assign(this)"/></td>
<td><input type="button" name="subtract" value="-" onclick = "Assign(this)"/></td>
</tr>

<tr>
<td><input type="button" name="seven" value="7" onclick = "Assign(this)"/></td>
<td><input type="button" name="eight" value="8" onclick = "Assign(this)"/></td>
<td><input type="button" name="nine" value="9" onclick = "Assign(this)"/></td>
<td><input type="button" name="multiply" value="*" onclick = "Assign(this)"/></td>
<td rowspan="2"><input type="button" name="equals" style = "height : 64px;" value="=" onclick = "Assign(this)"/></td>
</tr>

<tr>
<td><input type="button" name="zero" value="0" onclick = "Assign(this)"/></td>
<td><input type="button" name="negative" value="+/-" onclick = "Assign(this)"/></td>
<td><input type="button" name="modulus" value="%" onclick = "Assign(this)"/></td>
<td><input type="button" name="divide" value="/" onclick = "Assign(this)"/></td>
</tr>

</table>

</form>

</html>

________________
Technorati Tags:
 Facebook
Read More
Posted in | No comments

Sunday, 12 July 2009

Oracle Business Intelligence : Workaround / Solution to "[46036] Internal Assertion" Error

Posted on 23:49 by Unknown
Symptom:

When checking in changes to Oracle BI repository (RPD), Admintool fails with an error message:


[46036] Internal Assertion: Condition FALSE, file server/Utility/Generic/NQThreads/SUGThread.cpp, line 515


Solution / Workaround:

Edit <BI_HOME>/server/Config/NQSConfig.INI configuration file to increase the value of SERVER_THREAD_STACK_SIZE parameter. Replace the line SERVER_THREAD_STACK_SIZE = 0; with SERVER_THREAD_STACK_SIZE = 512 KB; and restart the Analytics server (SAS)

________________
Technorati Tags:
 Oracle |  Business Intelligence |  Siebel Analytics
Read More
Posted in | No comments

Friday, 5 June 2009

Mac OS X 10.5 Tip: Outgoing Only sendmail

Posted on 02:14 by Unknown
By default, sendmail is disabled on Mac OS X 10.5 (Leopard). If you just want to enable/disable sending outgoing mail, run the following highlighted commands.


% sudo postfix start
Password:
postfix/postfix-script: starting the Postfix mail system

% netstat -an | grep LIST | grep 25
tcp4 0 0 127.0.0.1.25 *.* LISTEN

% sudo postfix stop
postfix/postfix-script: stopping the Postfix mail system

% netstat -an | grep LIST | grep 25
%


One of several possible error messages [that might have lead you to this page] is pasted below. The above solution should fix it.


javax.mail.MessagingException: Could not connect to SMTP host: localhost, port: 25;
nested exception is:
java.net.ConnectException: Connection refused
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1391)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:412)
at javax.mail.Service.connect(Service.java:288)
at javax.mail.Service.connect(Service.java:169)
at javax.mail.Service.connect(Service.java:118)
at javax.mail.Transport.send0(Transport.java:188)
at javax.mail.Transport.send(Transport.java:118)
...
...
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:432)
at java.net.Socket.connect(Socket.java:520)
at java.net.Socket.connect(Socket.java:470)
at com.sun.mail.util.SocketFetcher.createSocket(SocketFetcher.java:233)
at com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:189)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1359)
... 9 more

Read More
Posted in | No comments

Saturday, 23 May 2009

Installing Siebel Web Extension (SWE) on top of Sun Java System Web Server 7.0

Posted on 01:16 by Unknown
As of today, Sun Java System Web Server 7.0 is not a certified platform to deploy Siebel 8.0 enterprise on. We are working with Oracle Corporation to make this certification happen so our customers can take advantage of the performance optimizations that went into the web server release 7.0.

Meanwhile those who want to give it a try can do so with little effort. In release SJSWS 7.0, the start/stop/restart/.. scripts were appropriately relocated to bin directory under the virtual web server instance. The installer for Siebel 8.0 Web Server Extension looks for the start script [of the web server] under the home directory of the virtual web server instance. (because it was the default location until the release of SJSWS 7.0). The installation fails if the installer cannot find the start script in the location it is expecting it to be.

Due to the relocation mentioned above, installation of the Siebel Web Server Extension fails at the very last step where it tries to modify the start script with a bunch of LD_PRELOADs so the Siebel Web Extension loads up and runs on the Sun Java System Web Server. To get around this failure, all you have to do is to create a symbolic link in the home directory of the virtual web server instance pointing to the startserv script residing in the bin directory.

The following example shows the necessary steps.

% pwd
/export/pspp/SJWS7U5/https-siebel-pspp

% ln -s bin/startserv start

% ls -l start
lrwxrwxrwx 1 pspp dba 13 May 17 17:01 start -> bin/startserv


Install Siebel Web Extension in the normal way. No other changes are required.

AFTER SWE INSTALLATION:

% ls -l start*
-rwxr-xr-x 1 pspp dba 4157 May 17 17:38 start
-rwxr-xr-x 1 pspp dba 3456 May 17 17:38 start_.bak

% mv bin/startserv bin/startserv.orig
% mv start bin/startserv



Notice that the Siebel installer actually made two copies of the startup script from the symbolic link. The original bin/startserv remained intact after the SWE installation.

Finally start the Web Server instance by running the startserv script. It should start with no issues.

% pwd
/export/pspp/SJWS7U5/https-siebel-pspp/bin

% ./startserv
Sun Java System Web Server 7.0U5 B03/10/2009 16:38
info: swe_init reports: SWE plug-in log file
info: CORE5076: Using [Java HotSpot(TM) Server VM, Version 1.5.0_15] from [Sun Microsystems Inc.]
info: HTTP3072: http-listener-1: http://siebel-pspp:8000 ready to accept requests
info: CORE3274: successful server startup


Before we conclude, do not forget the fact that Sun Java System Web Server 7.0 is not yet certified with Siebel 8.0 release. Use the instructions mentioned in this blog post at your own risk. However if you do like to take that risk, consider installing the latest release of Sun Java System Web Server, which is SJSWS 7.0 Update 5 as of this writing.

Stay tuned for the certification news though.

(Originally posted on:
http://blogs.sun.com/mandalika/entry/installing_siebel_web_extension_swe
)
_______________
Technorati Tags:
 Oracle |  Siebel |  CRM |  Solaris |  Sun Java System Web Server |  iPlanet
Read More
Posted in | No comments

Friday, 1 May 2009

Oracle E-Business Suite R12 Database Tier on Solaris 10 x64

Posted on 00:32 by Unknown
The long wait for this certification is over. Oracle Corporation finally announced support for Solaris 10 x64 as the certified E-Business Suite platform for the database tier. Oracle E-Business Suite Release 12 (12.0.4) is now certified with Oracle Database Server 10g R2 version 10.2.0.4 on the 'database tier only' (previously known as 'split configuration' in 11i) platform Sun Solaris x86/64.

The following Metalink documents might be of interest to Sun-Oracle customers who are waiting for this certification to happen.
  • Frequently Asked Questions: Oracle E-Business Suite Support on x86-64
  • Using Oracle E-Business Suite Release 12 with a Database Tier Only Platform on Oracle 10g Release 2
  • Interoperability Notes Oracle E-Business Suite Release 12 with Oracle Database 10g Release 2 (10.2.0)


_______________
Technorati Tags:
 Oracle |  E-Business Suite |  Oracle Applications |  Solaris
Read More
Posted in | No comments

Friday, 24 April 2009

Developing MySQL Database Applications With PHP

Posted on 00:50 by Unknown
A four part tutorial that explains the PHP / MySQL extensions - mysql, mysqli, and pdo_mysql - with simple examples is now accessible from Sun Developer Network. While most of the information presented in the tutorial is available elsewhere in bits and pieces, the real value-add is in the introduction of the MySQL native driver for PHP, mysqlnd.

Here is a brief description of all four parts in the series:

  • Part 1: Using the MySQL Improved Extension, mysqli -- describes mysqli, the MySQL Improved Extension that is the successor to the mysql extension

  • Part 2: Using the MySQL Extension, mysql -- describes the original extension designed to develop PHP applications that interact with a MySQL database

  • Part 3: Using the PDO Extension With MySQL Driver, pdo_mysql -- describes the pdo_mysql driver, which implements the PHP Data Objects (PDO) interface to access the MySQL Server from PHP

  • Part 4: Using the MySQL Native Driver for PHP, mysqlnd -- describes the MySQL native driver for PHP, mysqlnd, which is an alternative to the MySQL client library, libmysql, for connecting from PHP 5 and PHP 6 to MySQL Server 4.1 or later

Application developers who are new to the development of MySQL database applications with PHP are the target audience of this tutorial.

_______________
Technorati Tags:
 MySQL |  PHP |  mysqlnd |  PHP Extensions |  mysqli |  PDO |  pdo_mysql
Read More
Posted in | No comments

Wednesday, 15 April 2009

Exploring the Features of MySQL Connector/C++

Posted on 21:02 by Unknown
With the introduction of MySQL Connector/C++, now C++ application developers have one additional option to choose from, to connect to MySQL Server 5.1 or later from a C++ application. Admittedly, as of today, there isn't enough documentation with examples to show the capabilities [and gotchas] of MySQL Connector/C++. I tried to fill that gap with the technical article, Developing Database Applications Using MySQL Connector/C++. Hopefully it serves as a starting point for the C++ developers while waiting for the MySQL Connectors documentation team to publish the official documentation on MySQL Developer Zone.

While you are at it, don't forget to check the supplement document, Installing MySQL Connector/C++ from Source, in case if you want to build the driver on your own from the source code.

________________
Technorati Tags:
 MySQL |  Connector/C++
Read More
Posted in | No comments
Newer Posts Older Posts Home
Subscribe to: Posts (Atom)

Popular Posts

  • Achievement Award
    Got an Achievement Award/Certificate from Sun Microsystems, in recognition for my effort with Siebel Benchmark!! =:) Related post: http:...
  • C/C++/Java: ++ unary operator
    #include <stdio.h> int main() { int i = 5, j = 5; int total = 0; total = ++i + j++; printf("\ntotal o...
  • Blast from the Past : The Weekend Playlist #3
    The 80s contd., The 80s witnessed the rise of fine talent - so, it is only fitting to dedicate another complete playlist for the 80s. Her...
  • C/C++: Structure Vs Union
    A structure is a collection of items of different types; and each data item will have its own memory location. Where as only one item withi...
  • Linux: Frozen Xwindows
    If Xwindows seem frozen, the following simple key strokes may bring back the Xserver without the need for a reboot Two ways to kill the Xwi...
  • UNIX/Linux: File Permissions (chmod)
    A file's permissions are also known as its 'mode'; so to change them we need to use the 'chmod' command (change mode). T...
  • Sun C/C++: #pragma pack
    Let's have a look at the following program and the output bpte4500s001:/sunbuild1/giri/testcases/%cat aligndata.c #include <stdio.h...
  • C++: Virtual Function
    A virtual function allows derived classes to replace the implementation provided by the base class. The compiler makes sure the replacemen...
  • Miscellaneous Tips: Solaris, Oracle Database, Java, FMW
    [Solaris] Cleanup all IPC resources Run the following wrapper script with root user privileges. for i in `ipcs -a | awk '{ print $2 }...
  • Solaris: Resetting Forgotten Root Password
    Need physical or remote console access to the system to use these steps: Press Stop-A on the console or Ctrl-] and send brk from a remote...

Categories

  • 80s music playlist
  • bandwidth iperf network solaris
  • best
  • black friday
  • breakdown database groups locality oracle pmap sga solaris
  • buy
  • deal
  • ebiz ebs hrms oracle payroll
  • emca oracle rdbms database ORA-01034
  • friday
  • Garmin
  • generic+discussion software installer
  • GPS
  • how-to solaris mmap
  • impdp ora-01089 oracle rdbms solaris tips upgrade workarounds zombie
  • Magellan
  • music
  • Navigation
  • OATS Oracle
  • Oracle Business+Intelligence Analytics Solaris SPARC T4
  • oracle database flashback FDA
  • Oracle Database RDBMS Redo Flash+Storage
  • oracle database solaris
  • oracle database solaris resource manager virtualization consolidation
  • Oracle EBS E-Business+Suite SPARC SuperCluster Optimized+Solution
  • Oracle EBS E-Business+Suite Workaround Tip
  • oracle lob bfile blob securefile rdbms database tips performance clob
  • oracle obiee analytics presentation+services
  • Oracle OID LDAP ADS
  • Oracle OID LDAP SPARC T5 T5-2 Benchmark
  • oracle pls-00201 dbms_system
  • oracle siebel CRM SCBroker load+balancing
  • Oracle Siebel Sun SPARC T4 Benchmark
  • Oracle Siebel Sun SPARC T5 Benchmark T5-2
  • Oracle Solaris
  • Oracle Solaris Database RDBMS Redo Flash F40 AWR
  • oracle solaris rpc statd RPC troubleshooting
  • oracle solaris svm solaris+volume+manager
  • Oracle Solaris Tips
  • oracle+solaris
  • RDC
  • sale
  • Smartphone Samsung Galaxy S2 Phone+Shutter Tip Android ICS
  • solaris oracle database fmw weblogic java dfw
  • SuperCluster Oracle Database RDBMS RAC Solaris Zones
  • tee
  • thanksgiving sale
  • tips
  • TomTom
  • windows

Blog Archive

  • ▼  2013 (16)
    • ▼  December (3)
      • Blast from the Past : The Weekend Playlist #3
      • Measuring Network Bandwidth Using iperf
      • Blast from the Past : The Weekend Playlist #2
    • ►  November (2)
    • ►  October (1)
    • ►  September (1)
    • ►  August (1)
    • ►  July (1)
    • ►  June (1)
    • ►  May (1)
    • ►  April (1)
    • ►  March (1)
    • ►  February (2)
    • ►  January (1)
  • ►  2012 (14)
    • ►  December (1)
    • ►  November (1)
    • ►  October (1)
    • ►  September (1)
    • ►  August (1)
    • ►  July (1)
    • ►  June (2)
    • ►  May (1)
    • ►  April (1)
    • ►  March (1)
    • ►  February (1)
    • ►  January (2)
  • ►  2011 (15)
    • ►  December (2)
    • ►  November (1)
    • ►  October (2)
    • ►  September (1)
    • ►  August (2)
    • ►  July (1)
    • ►  May (2)
    • ►  April (1)
    • ►  March (1)
    • ►  February (1)
    • ►  January (1)
  • ►  2010 (19)
    • ►  December (3)
    • ►  November (1)
    • ►  October (2)
    • ►  September (1)
    • ►  August (1)
    • ►  July (1)
    • ►  June (1)
    • ►  May (5)
    • ►  April (1)
    • ►  March (1)
    • ►  February (1)
    • ►  January (1)
  • ►  2009 (25)
    • ►  December (1)
    • ►  November (2)
    • ►  October (1)
    • ►  September (1)
    • ►  August (2)
    • ►  July (2)
    • ►  June (1)
    • ►  May (2)
    • ►  April (3)
    • ►  March (1)
    • ►  February (5)
    • ►  January (4)
  • ►  2008 (34)
    • ►  December (2)
    • ►  November (2)
    • ►  October (2)
    • ►  September (1)
    • ►  August (4)
    • ►  July (2)
    • ►  June (3)
    • ►  May (3)
    • ►  April (2)
    • ►  March (5)
    • ►  February (4)
    • ►  January (4)
  • ►  2007 (33)
    • ►  December (2)
    • ►  November (4)
    • ►  October (2)
    • ►  September (5)
    • ►  August (3)
    • ►  June (2)
    • ►  May (3)
    • ►  April (5)
    • ►  March (3)
    • ►  February (1)
    • ►  January (3)
  • ►  2006 (40)
    • ►  December (2)
    • ►  November (6)
    • ►  October (2)
    • ►  September (2)
    • ►  August (1)
    • ►  July (2)
    • ►  June (2)
    • ►  May (4)
    • ►  April (5)
    • ►  March (5)
    • ►  February (3)
    • ►  January (6)
  • ►  2005 (72)
    • ►  December (5)
    • ►  November (2)
    • ►  October (6)
    • ►  September (5)
    • ►  August (5)
    • ►  July (10)
    • ►  June (8)
    • ►  May (9)
    • ►  April (6)
    • ►  March (6)
    • ►  February (5)
    • ►  January (5)
  • ►  2004 (36)
    • ►  December (1)
    • ►  November (5)
    • ►  October (12)
    • ►  September (18)
Powered by Blogger.

About Me

Unknown
View my complete profile