Questions tagged [bind]

This tag means different things in different contexts: consider using less ambiguous tags instead. Common meanings include: the bind function in socket programming; binding to naming contexts; the bind method in jQuery; BIND the DNS server (named), . For boost::bind in C++, use [boost-bind]. Do not use this tag just to say that you're binding something to something else.

  • In and , bind() is a system call that associates an IP address and port number with a socket.
  • In , Function.prototype.bind() is a method to attach a function to a fixed this value.
  • In , bind is a method to attach a handler to an event. This method was deprecated in jquery v3.0
  • In , 'bind' is a connect/authenticate step.
  • in , 'bind' is the process of associating an object with a name in a context.
  • in , 'bind' is the process of associating a remote object with a name in an RMI Registry.
  • In , 'bind' is the process of associating an exported object with a name in a COSNaming context.
  • In bind or binding refers to specifying the target of an inject request.
  • In , questions about the library's boost::bind function should use the tag instead and questions about the function std::bind should use the tag .
  • BIND, the Berkeley Internet Name Domain is the most commonly used DNS server software on the Internet. Questions about BIND are often off-topic for StackOverflow and may belong on SuperUser.com or unix.stackexchange.com.
  • In , "bind" often refers to the >>= operator. Questions about it should use the tag .

Do not use this tag just to indicate that you're binding something to something else — use tags that are related to the topic of your question.

4006 questions
17
votes
5 answers

How to remove an appended element with Jquery and why bind or live is causing elements to repeat

Now I know this basic question has been asked before, but I must be doing something wrong. I know that an appended element must bound before I can do anything to it. However, try as I might I can't get it to work. I am pulling in a message and…
user1197728
  • 181
  • 1
  • 1
  • 5
17
votes
5 answers

Bind selenium to a specific IP - Possible?

Like many, we start selenium server via the following command: java -jar selenium-server-standalone-2.21.0.jar What we found is that this opens selenium up on 0.0.0.0:4444 Started SocketListener on 0.0.0.0:4444 [USER @ BOX ~]# netstat -na | grep…
anonymous-one
  • 14,454
  • 18
  • 60
  • 84
16
votes
2 answers

Unable to unbind the window beforeunload event in Jquery

I have a page where the user can drag and drop objects and save them as an image.When a user navigates away from the page, the event beforeunload is fired. Now, this happens every time. What i want to do is, unbind the event if the user has saved…
bitblt
  • 217
  • 1
  • 3
  • 8
16
votes
3 answers

A replacement for std::bind2nd

I have a foo which is a std::vector. It represents the "edge" values for a set of ranges. For example, if foo is {1, 3, 5, 7, 11} then the ranges are 1-3, 3-5, 5-7, 7-11. Significantly for me, this equates to 4 periods. Note that each period…
P45 Imminent
  • 8,319
  • 4
  • 35
  • 78
16
votes
2 answers

Javascript function bind override (how to bind it to another object)

Is there a way to rebind a function that is already bound to another object via Function.prototype.bind? var a={}; var b={}; var c=function(){ alert(this===a); }; c(); // alerts false c=c.bind(a); c(); // alerts true c=c.bind(b); c(); // still…
optimizitor
  • 807
  • 13
  • 18
16
votes
2 answers

difference between hardlink and bind mount?

it might be a stupid question but: http://dwaves.de/2015/05/26/linux-search-find-files-locate-find-linux-locate-scope/ bind mounts under linux: as far as i understand it: you can mount the same dir in two different places. but where is the…
canoodle
  • 506
  • 5
  • 10
16
votes
2 answers

std::bind vs lambda performance

I wanted to time a few functions' execution and I've written myself a helper: using namespace std; template void timeExec(string name, Fun fun, Args... args) { auto start = chrono::steady_clock::now(); …
Adam Kosiorek
  • 1,438
  • 1
  • 13
  • 17
16
votes
4 answers

jQuery bind efficiency

I'm having issue with load speed using multiple jQuery binds on a couple thousands elements and inputs, is there a more efficient way of doing this? The site has the ability to switch between product lists via ajax calls, the page cannot refresh. …
clownshoes
  • 345
  • 2
  • 11
16
votes
5 answers

Why javascript bind doesn't work

function: function talk(){ console.log(this.name + " dice: "); } var Person = function(name, surname){ this.name = name; this.surname = surname; } var p = new Person("Mark", "Red"); talk.bind(p); what's wrong with bind?
Donovant
  • 3,091
  • 8
  • 40
  • 68
16
votes
7 answers

MySQLI binding params using call_user_func_array

Please see below my code. I am attempting to bind an array of paramenters to my prepared statement. I've been looking around on the web and can see I have to use call_user_func_array but cannot get it to work. The error I get is: "First argument is…
Columbo
  • 2,896
  • 7
  • 44
  • 54
16
votes
1 answer

WPF Bind to the list of installed printers

How to bind to the list of System.Drawing.Printing.PrinterSettings.InstalledPrinters, which is a static StringCollection, in WPF XAML. For example, to use it in a ComboBox, so a user can select the printer to use.
Mike de Klerk
  • 11,906
  • 8
  • 54
  • 76
15
votes
2 answers

Reason behind using 'instanceof function() {}'?

On Mozilla Developer Center, there is a page about the Function.prototype.bind function and provides a compatibility function for browsers which do not support this function. However, when analyzing this compatibility code I cannot find out why they…
pimvdb
  • 151,816
  • 78
  • 307
  • 352
15
votes
1 answer

Mistake with bind in "The C++ Programming Language [4th Edition] - Bjarne Stroustrup"

I found this code in Bjarne Stroustrup's book: The problem with this code is that variable i does not stay at 2, it is incremented to 3. You can check it here: https://wandbox.org/permlink/p5JC1nOA4pIpsgXb We do not have to use the std::ref() to…
Evelekk
  • 159
  • 7
15
votes
4 answers

How does function.apply.bind work in the following code?

So I get that an array of [200,599] is returned from the promise and the callback function inside spread is being passed into Function.apply.bind, but now I'm lost. How is the array of [200,599] split into x and y? How exactly does the apply.bind…
Gwater17
  • 2,018
  • 2
  • 19
  • 38
15
votes
5 answers

rndc: connect failed: 127.0.0.1#953: connection refused

This is a very annoying problem that i am having with the rndc reload I am getting the following error: rndc: connect failed: 127.0.0.1#953: connection refused However the following work fine, [root@cbgfx ~]# service named restart Stopping named: .…
user2650277
  • 6,289
  • 17
  • 63
  • 132