<div id="example-value"> or <div id="example_value">?
This site and Twitter use the first style. Facebook and Vimeo - the second.
Which one do you use and why?
<a href="facebook.com/sharer" target="_blank" >Share this</a>
How do I make this a certain width and height, in a new window, when the user clicks on it?
In firefox, the current code only opens up a new tab (not a new window)
I know that there are many API's like json,Facebook,twitter etc for developing related applications on iphone....but how to understand an API?This might be scilly question but I want to know how? what would you suggest for for a beginner?
Just wondering, if I load a site such as Facebook into a WebBrowser control how do I enter data into the form controls from WF/Desktop app?
Do I have to use the DOM?
How do I use the back and forward browser buttons to navigate my javascript/jQuery web application? I know I can do window.location.href = 'this_url#placeholder' and then perform the appropriate action. But when I do that, the browser scrolls to the element with that placeholder id (or to the top if there wasn't one). How do I get the browser to not scroll anywhere? I've seen this on other sites like facebook, what's the appropriate mechanism for this?
We are looking for Web Designers & Developers. Urgent Opening.
Profile:-
a) Have exp. in Designing websites in wordpress
b) Have Creativity in work
c) Send us your work – [email protected]
d) Min Exp. required: 2 + years
e) Can Integrate the Facebook, Twitter & other social networking websites.
To review our profile – please check – www.dicorporation.com & www.ismoip.com
Would any one please explain this instruction for me:
for (;;)
I have encountered several kinds of these mark (like in ajax code of facebook and in concurrent stuff of Java).
I'm trying to configure a couple of Cisco 1941 routes. The are both identical routers. Each as a HWIC-1T (Smart Serial interface) and a HWIC-3G-HSPA 3G interface. These routers are to be sent to remote sites. We have connectivity to one of the sites but if remote site A gors down we lose connectivity to remote site B.
The HWIC-1T is the primary WAN interface using frame relay joining the two remote sites
We want the HWIC-3G-HSPA to be usable for direct connectivity from head office to remote site B, and also the HWIC-3G-HSPA is do be used for comms between the remote sites when the frame relay is down (happens quite a bit).
I initialy tried to do dynamic routing using EIGRP however in my lab setup of laptop - 1941 - 1941 - laptop, I was unable to get end to end connectivity. I later settled on static routing and have got end to end connectivity but only over frame relay, not the HWIC-3G-HSPA.
The sanitized running config for remote site A:
version 15.1
service tcp-keepalives-in
service tcp-keepalives-out
service timestamps debug datetime msec
service timestamps log datetime msec
service password-encryption
service udp-small-servers
service tcp-small-servers
!
hostname remoteA
!
boot-start-marker
boot-end-marker
!
!
logging buffered 51200 warnings
enable secret 5 censored
!
no aaa new-model
clock timezone wst 8 0
!
no ipv6 cef
ip source-route
ip cef
!
ip domain name yourdomain.com
multilink bundle-name authenticated
!
chat-script gsm "" "ATDT*98*1#" TIMEOUT 30 "CONNECT"
!
username admin privilege 15 secret 5 censored
!
controller Cellular 0/1
!
interface Embedded-Service-Engine0/0
no ip address
shutdown
!
interface GigabitEthernet0/0
ip address 192.168.2.5 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0/0
ip address 10.1.1.2 255.255.255.252
encapsulation frame-relay
cdp enable
frame-relay interface-dlci 16
frame-relay lmi-type ansi
!
interface Cellular0/1/0
ip address negotiated
encapsulation ppp
dialer in-band
dialer idle-timeout 2147483
dialer string gsm
dialer-group 1
async mode interactive
ppp chap hostname censored
ppp chap password 7 censored
cdp enable
!
interface Cellular0/1/1
no ip address
encapsulation ppp
!
interface Dialer0
no ip address
!
ip forward-protocol nd
!
no ip http server
no ip http secure-server
!
ip route 0.0.0.0 0.0.0.0 Serial0/0/0 210 permanent
ip route 0.0.0.0 0.0.0.0 Cellular0/1/0 220 permanent
ip route 172.31.2.0 255.255.255.0 Cellular0/1/0 permanent
ip route 192.168.3.0 255.255.255.0 10.1.1.1 permanent
ip route 192.168.3.0 255.255.255.0 Cellular0/1/0 210 permanent
!
access-list 1 permit any
dialer-list 1 protocol ip list 1
!
control-plane
!
line con 0
logging synchronous
login local
line aux 0
line 2
no activation-character
no exec
transport preferred none
transport input all
transport output pad telnet rlogin lapb-ta mop udptn v120 ssh
stopbits 1
line 0/1/0
exec-timeout 0 0
script dialer gsm
login
modem InOut
no exec
transport input all
rxspeed 7200000
txspeed 5760000
line 0/1/1
no exec
rxspeed 7200000
txspeed 5760000
line vty 0 4
access-class 23 in
privilege level 15
password 7 censored
login local
transport input all
line vty 5 15
access-class 23 in
privilege level 15
password 7 censored
login local
transport input all
line vty 16 1370
password 7 censored
login
transport input all
!
scheduler allocate 20000 1000
end
The sanitized running config for remote site B:
version 15.1
service tcp-keepalives-in
service tcp-keepalives-out
service timestamps debug datetime msec
service timestamps log datetime msec
service password-encryption
service udp-small-servers
service tcp-small-servers
!
hostname remoteB
!
boot-start-marker
boot-end-marker
!
logging buffered 51200 warnings
enable secret 5 censored
!
no aaa new-model
clock timezone wst 8 0
!
no ipv6 cef
ip source-route
ip cef
!
no ip domain lookup
ip domain name yourdomain.com
multilink bundle-name authenticated
!
chat-script gsm "" "ATDT*98*1#" TIMEOUT 30 "CONNECT"
username admin privilege 15 secret 5 censored
!
controller Cellular 0/1
!
interface Embedded-Service-Engine0/0
no ip address
shutdown
!
interface GigabitEthernet0/0
ip address 192.168.3.1 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0/0
ip address 10.1.1.1 255.255.255.252
encapsulation frame-relay
clock rate 2000000
cdp enable
frame-relay interface-dlci 16
frame-relay lmi-type ansi
frame-relay intf-type dce
!
interface Cellular0/1/0
ip address negotiated
encapsulation ppp
dialer in-band
dialer idle-timeout 2147483
dialer string gsm
dialer-group 1
async mode interactive
ppp chap hostname censored
ppp chap password 7 censored
ppp ipcp dns request
cdp enable
!
interface Cellular0/1/1
no ip address
encapsulation ppp
!
interface Dialer0
no ip address
!
ip forward-protocol nd
!
no ip http server
no ip http secure-server
!
ip route 0.0.0.0 0.0.0.0 Serial0/0/0 210 permanent
ip route 0.0.0.0 0.0.0.0 Cellular0/1/0 220 permanent
ip route 172.31.2.0 255.255.255.0 Cellular0/1/0 permanent
ip route 192.168.2.0 255.255.255.0 10.1.1.2 permanent
ip route 192.168.2.0 255.255.255.0 Cellular0/1/0 210 permanent
!
kron occurrence PING in 1 recurring
policy-list ICMP
!
access-list 1 permit any
dialer-list 1 protocol ip list 1
!
control-plane
!
line con 0
logging synchronous
login local
line aux 0
line 2
no activation-character
no exec
transport preferred none
transport input all
transport output pad telnet rlogin lapb-ta mop udptn v120 ssh
stopbits 1
line 0/1/0
exec-timeout 0 0
script dialer gsm
login
modem InOut
no exec
transport input all
rxspeed 7200000
txspeed 5760000
line 0/1/1
no exec
rxspeed 7200000
txspeed 5760000
line vty 0 4
access-class 23 in
privilege level 15
password 7 censored
login
transport input all
line vty 5 15
access-class 23 in
privilege level 15
password 7 censored
login
transport input all
line vty 16 1370
password 7 censored
login
transport input all
!
scheduler allocate 20000 1000
end
The last problem I'm having is the 3G interfaces go down after only a few minutes of inactivity. I've tried using kron to ping the local HWIC-3G-HSPA interface (cellular 0/1/0) every minute but that hasn't been successful. Manually pinging the IP assigned (by the telco) to ce0/1/0 does bring the interface up.
Any ideas?
Thanks
I am implemeting a facebook application in rails using facebooker plugin, therefore it is very important to use this architecture if i want to update multiple DOM in my page.
if my code works in a regular rails application it would work in my facebook application.
i am trying to use ajax to let the user know that the comment was sent, and update the comments bloc.
migration:
class CreateComments < ActiveRecord::Migration
def self.up
create_table :comments do |t|
t.string :body
t.timestamps
end
end
def self.down
drop_table :comments
end
end
controller:
class CommentsController < ApplicationController
def index
@comments=Comment.all
end
def create
@comment=Comment.create(params[:comment])
if request.xhr?
@comments=Comment.all
render :json=>{:ids_to_update=>[:all_comments,:form_message],
:all_comments=>render_to_string(:partial=>"comments" ),
:form_message=>"Your comment has been added." }
else
redirect_to comments_url
end
end
end
view:
<script>
function update_count(str,message_id) {
len=str.length;
if (len < 200) {
$(message_id).innerHTML="<span style='color: green'>"+
(200-len)+" remaining</span>";
} else {
$(message_id).innerHTML="<span style='color: red'>"+
"Comment too long. Only 200 characters allowed.</span>";
}
}
function update_multiple(json) {
for( var i=0; i<json["ids_to_update"].length; i++ ) {
id=json["ids_to_update"][i];
$(id).innerHTML=json[id];
}
}
</script>
<div id="all_comments" >
<%= render :partial=>"comments/comments" %>
</div>
Talk some trash: <br />
<% remote_form_for Comment.new,
:url=>comments_url,
:success=>"update_multiple(request)" do |f|%>
<%= f.text_area :body,
:onchange=>"update_count(this.getValue(),'remaining');" ,
:onkeyup=>"update_count(this.getValue(),'remaining');"
%> <br />
<%= f.submit 'Post'%>
<% end %>
<p id="remaining" > </p>
<p id="form_message" > </p>
<br><br>
<br>
if i try to do alert(json) in the first line of the update_multiple function , i got an [object Object].
if i try to do alert(json["ids_to_update"][0]) in the first line of the update_multiple function , there is no dialog box displayed.
however the comment got saved but nothing is updated.
it seems like the object sent by rails is nil or cant be parsed by JSON.parse(json).
questions:
1.how can javascript and rails know that i am dealing with json objects?deos ROR sent it a object format or a text format?how can it check that the json object has been sent
2.how can i see what is the returned json?do i have to parse it?how?
2.how can i debug this problem?
3.how can i get it to work?
I have created a blogging system with php+postgresql.
Now I want to add a web chat ( in REAL TIME for Million of users simultaneously ) where every message is saved in database.
I am thinking to use Erlang+Mnesia on a different webserver for this issue.
Message's table will be like this:
message_id, user_id, message, date
user_id should be related with users table in Postgresql database in another webserver.
How can I do that without lose performance ?
If you have any other creative solutions tell me please ;).
Hello
I'm learning my way about socket programming in C (referring to Beej).
Here is a simple multi-user chat server i'm trying to implement:
http://pastebin.com/gDzd0WqP
On runtime, it gives Bus Error. It's coming from the lines 68-78.
Help me trace the source of the problem?
in fact, WHY is my code even REACHING that particular region? I've just run the server. no clients have connected.. :@
ps - i know my code is highly unreliable (no error checks anywhere), but i WILL do that at a later stage, i just want to TEST the functionality of the code before implementing it in all it's glory ;)
I'm having a lot of difficulty getting strophe's 'attach()' function working.
I am working on a social network where users will be surfing pages and at the same time keep their chat connection on. I don't want to reconnect/reauthorize on every page so as per this link (http://groups.google.com/group/strophe/browse_thread/thread/430da5e788278f3a/93c48c88164f382f?show_docid=93c48c88164f382f&fwc=1) i am storing the SID and RID into a cookie onunload.
On the next page when i try to use the new SID and RID (after incrementing it by 1) my session is already destroyed. Ejabberd reports "Error on HTTP put. Reason: bad_key"
WTF is happening?
hi,
I want to make work PopupManager as a Tooltip.
So I want to create a popup everytime I move the mouse over my component and make it disappear when I move the mouse out.
Moreover, I have many components in my canvas, so I need it not to be too expensive.
Also, when I move the mouse out from the component, but over the pop-up, it should not disappear, because I want to click on the buttons inside it.
I need something similar to gmail chat popups. Is it doable with PopupManager ?
thanks
Hi All,
I open a pop-up window using following code in main.html
function openwindow(url)
{
window.open(url,
"mywindow","location=1,status=1,scrollbars=1,resizable=no,width=650,height=650");
}
Open
In My child.html i used
function closewindow()
{
self.close();
}
function closeIt()
{
return "Your chat will be terminated. Are you sure?"
}
< a href="javascript:void(0)" onclick="closewindow();"Close Window< /a
When i click on close window it gize me alert message that i given on event onbeforeunload but it not close the window when i click on Ok.Also this happens only in I.E. & working fine in mozilla, netscape, safari. I checked it on IE6 & IE8
Any help is Appreciated.
Regards,
Salil Gaikwad
Hi All,
I want to run an XMPP server (Openfire) and register an external component to handle the messages it will recieve (using the Whack library). The external component will run my game logic and I will be using XMPP to send player moves to the server and status updates in the other direction. The bonus with XMPP is that we get built in chat for free.
The trouble is, although Ignite look fairly established, I can't find a tutorial on how to write, register and debug an External XMPP component written with Whack, there are very few in general for that matter.
I am not invested in either the server implementation or the External Component library, java is just my language of choice. If I was to move to Erlang or Scala or something it would have to be a very simple in that language.
A single tutorial or example would go a long way here, I just need an basic External XMPP component pretty please!
Kind regards,
Gavin
Hello guys,
I'm currently developing an audio engine that is used in voice network chat software.
Everything is working fine - capture/playback/mixing channels.
The problem is in using it under Windows XP. I've been getting user reports with information
that their global system volume is set to zero after launching the application.
I'm assuming that happens because of WaveOut/DSound conflict.
How can I force DSound not to affect system volume?
Playback device is initialized:
DirectSoundCreate8(&GUID, &pAudio, NULL);
and:
pAudio-SetCooperativeLevel(parentWnd, DSSCL_PRIORITY);
I'm currently not able to debug the application, cause I'm using Vista and everything is OK.
Hope you can help me with this issue!
Thanks a Lot!
Regards,
Anton.
I am developing a Cocoa application which involves a chat element. One approach I've considered is using Websockets to handle client-server communication. This would be particularly desirable because chats will also be displayed on a website, and using Websockets could make the implementation very simple.
So: would it be possible to use a WebView element, and use Websockets within it? (I know Safari doesn't support Websockets yet, so I imagine this is not possible?)
Failing that, are there any Websocket client libraries for C, Objective C, or any other language I could successfully embed within my application?
Suggestions welcomed.
I want to code a peer-to-peer like chat program in C#. I am trying to figure out how the networking would work. I know that the concept is that each peer is a client and a server at the same time. It can connect and be connected to. But my question is, how do you connect to a computer behind a router without the port being forwarded to that computer? I know things like Bittorrent do this with no problem. I was planning on using a tracker to keep a list of peers and the ports they listen on, but I still don't understand how to get through the router issue. Could someone please explain?
We're creating a web site offering one to many video chat and trying to decide on which of these streaming servers to go with. Looking at around 256kbps live streams, hoping to achieve at least 1000 simultaneous streams on one 8-core server.
Wowza is cheaper (1k vs 5k for FMS), and appears to be used successfully by many sites (StreamLive, Justin.TV, etc.). However, some people have expressed that it may be more difficult to work with. I.e. fine-tuning it, less documentation, integration with ASP.Net code, etc.
Wondering if anyone with real-world experience with either of these servers can advise regarding how easy or difficult to use and integrate they are for a site like this. Also wondering if there is any performance difference (lag, etc.).
I want to have interactions between visitors on my site.
Imagine a chat room.
It basically involves getting the data from everyone and sending it to everyone, this can be done by ajax and what not but I wonder if there is something already there in the wild that would do the heavy lifting for me. I have to say that I got very lost once I start programming Ajax, dont even know how to make tests for it...
I have found the Q42multiplayer library that looks like what I want but they use C# as backend. There is something similar or any other multiplayer thingy I can get some idea or rip some code from (the whole thing will be opensource) for Ruby on Rails?
I am designing a client-server chat application in Java. This is a secure application where the messages are exchanged using cryptographic algorithms. I have one server and it can support many clients. My problem is that when one client logs on the server it works fine, but when another user logs into the system, the server starts giving me bad padding exceptions for the encrypted text.
I am not able to figure out the problem, according to my logic, when new connection request to server is made, the server creates a thread for listening to the client. Is it possible that once the instance of thread class is created, it does all the processing correctly for the first client, but not for the second client because the variables in server listener thread class already have some previous value, and thus the encrypted text is not decrypted properly?
Please advise how I can make this process more robust so that the number of clients does not affect how well the server functions.
Hi, I am collaborating with someone on a project and currently use Skype for collaboration. I like it because we can be on a call to say things that are hard to say by typing out. We can share our screens so we can help with code writing. And we can use the text chat to copy-paste code between each other. We also use Subversion for version control.
I just wanted to know what other people used for collaborating with others so I could see whats out there to use.
Thanks!
ok folks, heres my dilemma i want to make a chat program that uses sms as its base engine.. to do this i need to communicate with my gsm phone via bluetooth attached to com 7 on my computer.. i can do this fine using hyperterminal, tera term etc. but to hav an un-obtrusive, friendly interface i need a command line tool to send AT commands, (and receive responses) to/from my mobile phone through my com port.. i have been searching for days to no avail.. please help