This is a brief code piece how to share sessions across ASP Classic and ASP.NET. Having to make some changes on a classic site and I would rather not keep writing classic. So after I migrated the site to ASP.NET using DLRSOFT.ASP, I needed to make sure that I can access the ASP Classic Session without replacing destroying the ASP Classic code base. So I got this gem from Jonavis but I have made a few updates to it to make it work better.
This is a page called aspsession.asp. This page allows me to send and receive ASP Classic session variables.
<%@ Language=VBScript %>
<%Option Explicit%>
<%Response.Expires=-1%>
<%
Dim strMode, strName, strValue
If Request.ServerVariables("REMOTE_ADDR") = Request.ServerVariables("LOCAL_ADDR") Then
strMode = Request.QueryString("mode")
strName = Request.QueryString("name")
If strMode = "get" Then
Response.Write(Session(strName))
ElseIf strMode = "set" Then
strValue = Request.QueryString("value")
Session(strName) = strValue
End If
End If
%>
Then this is the C# logic I plugged in so that I can send and receive the session from ASP Classic.
public static object Get(string name)
{
HttpContext context = HttpContext.Current;
object value = null;
String[] cookies = context.Request.Cookies.AllKeys;
System.Uri uri = context.Request.Url;
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(uri.Scheme + "://" + uri.Host + ":" + uri.Port.ToString() + "/Services/AspSession.asp?mode=get&name=" + name);
for (int i = 0; i < cookies.Length; i++)
{
HttpCookie cookie = context.Request.Cookies[cookies[i]];
if (cookie.Name.StartsWith("ASPSESSION"))
{
request.Headers.Add("Cookie: " + cookie.Name + "=" + cookie.Value);
}
}
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Stream responseStream = response.GetResponseStream();
System.Text.Encoding encode = System.Text.Encoding.GetEncoding("utf-8");
StreamReader readStream = new StreamReader(responseStream, encode);
value = readStream.ReadToEnd();
response.Close();
readStream.Close();
return value;
}
public static void Set(string name, object value)
{
HttpContext context = HttpContext.Current;
String[] cookies = context.Request.Cookies.AllKeys;
System.Uri uri = context.Request.Url;
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(uri.Scheme + "://" + uri.Host + ":" + uri.Port.ToString() + "/Services/aspsession.asp?mode=set&name=" + context.Server.UrlEncode(name) + "&value=" + context.Server.UrlEncode(value.ToString()));
for (int i = 0; i < cookies.Length; i++)
{
HttpCookie cookie = context.Request.Cookies[cookies[i]];
if (cookie.Name.StartsWith("ASPSESSION"))
{
request.Headers.Add("Cookie: " + cookie.Name + "=" + cookie.Value);
}
}
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Stream responseStream = response.GetResponseStream();
}
After that, this method simply works.
Looks like Apache Log4Net decided to take down the pattern page. I still need it so posting it here.
A flexible layout configurable with pattern string.
For a list of all members of this type, see PatternLayout Members.
Thread Safety
Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.
Remarks
The goal of this class is to Format a LoggingEvent as a string. The results depend on the conversion pattern.
The conversion pattern is closely related to the conversion pattern of the printf function in C. A conversion pattern is composed of literal text and format control expressions called conversion specifiers.
You are free to insert any literal text within the conversion pattern.
Each conversion specifier starts with a percent sign (%) and is followed by optional format modifiers and a conversion pattern name. The conversion pattern name specifies the type of data, e.g. logger, level, date, thread name. The format modifiers control such things as field width, padding, left and right justification. The following is a simple example.
Let the conversion pattern be "%-5level [%thread]: %message%newline" and assume that the log4net environment was set to use a PatternLayout. Then the statements
[C#]
ILog log = LogManager.GetLogger(typeof(TestApp));
log.Debug("Message 1");
log.Warn("Message 2");
would yield the output
DEBUG [main]: Message 1
WARN [main]: Message 2
Note that there is no explicit separator between text and conversion specifiers. The pattern parser knows when it has reached the end of a conversion specifier when it reads a conversion character. In the example above the conversion specifier %-5level means the level of the logging event should be left justified to a width of five characters.
The recognized conversion pattern names are:
Conversion Pattern Name |
Effect |
a |
Equivalent to appdomain |
appdomain |
Used to output the friendly name of the AppDomain where the logging event was generated. |
aspnet-cache |
Used to output all cache items in the case of %aspnet-cache or just one named item if used as %aspnet-cache{key}
This pattern is not available for Compact Framework or Client Profile assemblies.
|
aspnet-context |
Used to output all context items in the case of %aspnet-context or just one named item if used as %aspnet-context{key}
This pattern is not available for Compact Framework or Client Profile assemblies.
|
aspnet-request |
Used to output all request parameters in the case of %aspnet-request or just one named param if used as %aspnet-request{key}
This pattern is not available for Compact Framework or Client Profile assemblies.
|
aspnet-session |
Used to output all session items in the case of %aspnet-session or just one named item if used as %aspnet-session{key}
This pattern is not available for Compact Framework or Client Profile assemblies.
|
c |
Equivalent to logger |
C |
Equivalent to type |
class |
Equivalent to type |
d |
Equivalent to date |
date |
Used to output the date of the logging event in the local time zone. To output the date in universal time use the %utcdate pattern. The date conversion specifier may be followed by a date format specifier enclosed between braces. For example, %date{HH:mm:ss,fff} or %date{dd MMM yyyy HH:mm:ss,fff}. If no date format specifier is given then ISO8601 format is assumed (Iso8601DateFormatter).
The date format specifier admits the same syntax as the time pattern string of the ToString.
For better results it is recommended to use the log4net date formatters. These can be specified using one of the strings "ABSOLUTE", "DATE" and "ISO8601" for specifying AbsoluteTimeDateFormatter, DateTimeDateFormatter and respectively Iso8601DateFormatter. For example, %date{ISO8601} or %date{ABSOLUTE}.
These dedicated date formatters perform significantly better than ToString.
|
exception |
Used to output the exception passed in with the log message.
If an exception object is stored in the logging event it will be rendered into the pattern output with a trailing newline. If there is no exception then nothing will be output and no trailing newline will be appended. It is typical to put a newline before the exception and to have the exception as the last data in the pattern.
|
F |
Equivalent to file |
file |
Used to output the file name where the logging request was issued.
WARNING Generating caller location information is extremely slow. Its use should be avoided unless execution speed is not an issue.
See the note below on the availability of caller location information.
|
identity |
Used to output the user name for the currently active user (Principal.Identity.Name).
WARNING Generating caller information is extremely slow. Its use should be avoided unless execution speed is not an issue.
|
l |
Equivalent to location |
L |
Equivalent to line |
location |
Used to output location information of the caller which generated the logging event.
The location information depends on the CLI implementation but usually consists of the fully qualified name of the calling method followed by the callers source the file name and line number between parentheses.
The location information can be very useful. However, its generation is extremely slow. Its use should be avoided unless execution speed is not an issue.
See the note below on the availability of caller location information.
|
level |
Used to output the level of the logging event.
|
line |
Used to output the line number from where the logging request was issued.
WARNING Generating caller location information is extremely slow. Its use should be avoided unless execution speed is not an issue.
See the note below on the availability of caller location information.
|
logger |
Used to output the logger of the logging event. The logger conversion specifier can be optionally followed by precision specifier, that is a decimal constant in brackets.
If a precision specifier is given, then only the corresponding number of right most components of the logger name will be printed. By default the logger name is printed in full.
For example, for the logger name "a.b.c" the pattern %logger{2} will output "b.c".
|
m |
Equivalent to message |
M |
Equivalent to method |
message |
Used to output the application supplied message associated with the logging event.
|
mdc |
The MDC (old name for the ThreadContext.Properties) is now part of the combined event properties. This pattern is supported for compatibility but is equivalent to property.
|
method |
Used to output the method name where the logging request was issued.
WARNING Generating caller location information is extremely slow. Its use should be avoided unless execution speed is not an issue.
See the note below on the availability of caller location information.
|
n |
Equivalent to newline |
newline |
Outputs the platform dependent line separator character or characters.
This conversion pattern offers the same performance as using non-portable line separator strings such as "\n", or "\r\n". Thus, it is the preferred way of specifying a line separator.
|
ndc |
Used to output the NDC (nested diagnostic context) associated with the thread that generated the logging event.
|
p |
Equivalent to level |
P |
Equivalent to property |
properties |
Equivalent to property |
property |
Used to output the an event specific property. The key to lookup must be specified within braces and directly following the pattern specifier, e.g. %property{user} would include the value from the property that is keyed by the string 'user'. Each property value that is to be included in the log must be specified separately. Properties are added to events by loggers or appenders. By default the log4net:HostName property is set to the name of machine on which the event was originally logged.
If no key is specified, e.g. %property then all the keys and their values are printed in a comma separated list.
The properties of an event are combined from a number of different contexts. These are listed below in the order in which they are searched.
- the event properties
- The event has Properties that can be set. These properties are specific to this event only.
- the thread properties
- The Properties that are set on the current thread. These properties are shared by all events logged on this thread.
- the global properties
- The Properties that are set globally. These properties are shared by all the threads in the AppDomain.
|
r |
Equivalent to timestamp |
stacktrace |
Used to output the stack trace of the logging event The stack trace level specifier may be enclosed between braces. For example, %stacktrace{level}. If no stack trace level specifier is given then 1 is assumed
Output uses the format: type3.MethodCall3 > type2.MethodCall2 > type1.MethodCall1
This pattern is not available for Compact Framework assemblies.
|
stacktracedetail |
Used to output the stack trace of the logging event The stack trace level specifier may be enclosed between braces. For example, %stacktracedetail{level}. If no stack trace level specifier is given then 1 is assumed
Output uses the format: type3.MethodCall3(type param,...) > type2.MethodCall2(type param,...) > type1.MethodCall1(type param,...)
This pattern is not available for Compact Framework assemblies.
|
t |
Equivalent to thread |
timestamp |
Used to output the number of milliseconds elapsed since the start of the application until the creation of the logging event.
|
thread |
Used to output the name of the thread that generated the logging event. Uses the thread number if no name is available.
|
type |
Used to output the fully qualified type name of the caller issuing the logging request. This conversion specifier can be optionally followed by precision specifier, that is a decimal constant in brackets.
If a precision specifier is given, then only the corresponding number of right most components of the class name will be printed. By default the class name is output in fully qualified form.
For example, for the class name "log4net.Layout.PatternLayout", the pattern %type{1} will output "PatternLayout".
WARNING Generating the caller class information is slow. Thus, its use should be avoided unless execution speed is not an issue.
See the note below on the availability of caller location information.
|
u |
Equivalent to identity |
username |
Used to output the WindowsIdentity for the currently active user.
WARNING Generating caller WindowsIdentity information is extremely slow. Its use should be avoided unless execution speed is not an issue.
|
utcdate |
Used to output the date of the logging event in universal time. The date conversion specifier may be followed by a date format specifier enclosed between braces. For example, %utcdate{HH:mm:ss,fff} or %utcdate{dd MMM yyyy HH:mm:ss,fff}. If no date format specifier is given then ISO8601 format is assumed (Iso8601DateFormatter).
The date format specifier admits the same syntax as the time pattern string of the ToString.
For better results it is recommended to use the log4net date formatters. These can be specified using one of the strings "ABSOLUTE", "DATE" and "ISO8601" for specifying AbsoluteTimeDateFormatter, DateTimeDateFormatter and respectively Iso8601DateFormatter. For example, %utcdate{ISO8601} or %utcdate{ABSOLUTE}.
These dedicated date formatters perform significantly better than ToString.
|
w |
Equivalent to username |
x |
Equivalent to ndc |
X |
Equivalent to mdc |
% |
The sequence %% outputs a single percent sign.
|
The single letter patterns are deprecated in favor of the longer more descriptive pattern names.
By default the relevant information is output as is. However, with the aid of format modifiers it is possible to change the minimum field width, the maximum field width and justification.
The optional format modifier is placed between the percent sign and the conversion pattern name.
The first optional format modifier is the left justification flag which is just the minus (-) character. Then comes the optional minimum field width modifier. This is a decimal constant that represents the minimum number of characters to output. If the data item requires fewer characters, it is padded on either the left or the right until the minimum width is reached. The default is to pad on the left (right justify) but you can specify right padding with the left justification flag. The padding character is space. If the data item is larger than the minimum field width, the field is expanded to accommodate the data. The value is never truncated.
This behavior can be changed using the maximum field width modifier which is designated by a period followed by a decimal constant. If the data item is longer than the maximum field, then the extra characters are removed from the beginning of the data item and not from the end. For example, it the maximum field width is eight and the data item is ten characters long, then the first two characters of the data item are dropped. This behavior deviates from the printf function in C where truncation is done from the end.
Below are various format modifier examples for the logger conversion specifier.
Format modifier |
left justify |
minimum width |
maximum width |
comment |
%20logger |
false |
20 |
none |
Left pad with spaces if the logger name is less than 20 characters long.
|
%-20logger |
true |
20 |
none |
Right pad with spaces if the logger name is less than 20 characters long.
|
%.30logger |
NA |
none |
30 |
Truncate from the beginning if the logger name is longer than 30 characters.
|
%20.30logger |
false |
20 |
30 |
Left pad with spaces if the logger name is shorter than 20 characters. However, if logger name is longer than 30 characters, then truncate from the beginning.
|
%-20.30logger |
true |
20 |
30 |
Right pad with spaces if the logger name is shorter than 20 characters. However, if logger name is longer than 30 characters, then truncate from the beginning.
|
Note about caller location information.
The following patterns %type %file %line %method %location %class %C %F %L %l %M
all generate caller location information. Location information uses the System.Diagnostics.StackTrace
class to generate a call stack. The caller's information is then extracted from this stack.
CAUTION���
The System.Diagnostics.StackTrace
class is not supported on the .NET Compact Framework 1.0 therefore caller location information is not available on that framework.
CAUTION���
The System.Diagnostics.StackTrace
class has this to say about Release builds:
"StackTrace information will be most informative with Debug build configurations. By default, Debug builds include debug symbols, while Release builds do not. The debug symbols contain most of the file, method name, line number, and column information used in constructing StackFrame and StackTrace objects. StackTrace might not report as many method calls as expected, due to code transformations that occur during optimization."
This means that in a Release build the caller information may be incomplete or may not exist at all! Therefore caller location information cannot be relied upon in a Release build.
Additional pattern converters may be registered with a specific PatternLayout instance using the AddConverter method.
Example
This is a more detailed pattern.
%timestamp [%thread] %level %logger %ndc - %message%newline
A similar
pattern except that the relative time is right padded if less than 6 digits, thread name is right padded if less than 15 characters and truncated if longer and the logger name is left padded if shorter than 30 characters and truncated if longer.
%-6timestamp [%15.15thread] %-5level %30.30logger %ndc - %message%newline
Requirements
Namespace: log4net.Layout
Assembly: log4net (in log4net.dll)
See Also
PatternLayout Members | log4net.Layout Namespace
First we need to capture the cursor position within the Div it self.
$scope.editorSelection;
$scope.SetupEditor = function () {
var editable = document.getElementById('editor'),
selection, range;
var captureSelection = function (e) {
// Don't capture selection outside editable region
var isOrContainsAnchor = false,
isOrContainsFocus = false,
sel = window.getSelection(),
parentAnchor = sel.anchorNode,
parentFocus = sel.focusNode;
while (parentAnchor && parentAnchor != document.documentElement) {
if (parentAnchor == editable) {
isOrContainsAnchor = true;
}
parentAnchor = parentAnchor.parentNode;
}
while (parentFocus && parentFocus != document.documentElement) {
if (parentFocus == editable) {
isOrContainsFocus = true;
}
parentFocus = parentFocus.parentNode;
}
if (!isOrContainsAnchor || !isOrContainsFocus) {
return;
}
selection = window.getSelection();
// Get range (standards)
if (selection.getRangeAt !== undefined) {
range = selection.getRangeAt(0);
// Get range (Safari 2)
} else if (
document.createRange &&
selection.anchorNode &&
selection.anchorOffset &&
selection.focusNode &&
selection.focusOffset
) {
range = document.createRange();
range.setStart(selection.anchorNode, selection.anchorOffset);
range.setEnd(selection.focusNode, selection.focusOffset);
} else {
// Failure here, not handled by the rest of the script.
// Probably IE or some older browser
}
$scope.editorSelection = range;
};
editable.onkeyup = captureSelection;
}
From here, we need to be able to insert HTML at the selection when we choose to.
function insertHtmlAfterSelection(html) {
var range, expandedSelRange, node;
if ($scope.editorSelection) {
range = $scope.editorSelection;
expandedSelRange = range.cloneRange();
range.collapse(false);
var el = document.createElement("div");
el.innerHTML = html;
var frag = document.createDocumentFragment(), node, lastNode;
while ((node = el.firstChild)) {
lastNode = frag.appendChild(node);
}
range.insertNode(frag);
}
}
That will be it.
Requirements were to make a very high precision stop watch class for one of our projects. This is what we came up with. This class is used in one application by many sports teams around the world.
public class StopwatchWrapper : INotifyPropertyChanged
{
public event PropertyChangedEventHandler PropertyChanged;
Timer timer;
private bool _isPaused;
/// <summary>
/// is the clock currently counting down.
/// </summary>
public bool IsPaused
{
get { return _isPaused; }
set
{
_isPaused = value;
OnPropertyChanged("IsPaused");
}
}
/// <summary>
/// we need to track how many milliseconds occured since the last elapsed timer interval.
/// </summary>
private long _millisecondsSinceLastInterval = 0;
private bool _isRunning;
/// <summary>
/// is the clock currently counting down.
/// </summary>
public bool IsRunning
{
get { return _isRunning; }
set
{
_isRunning = value;
OnPropertyChanged("IsRunning");
}
}
private long _timerLength;
public long TimerLength
{
get { return _timerLength; }
set
{
_timerLength = value;
OnPropertyChanged("TimerLength");
}
}
private DateTime _startTime;
public DateTime StartTime
{
get { return _startTime; }
set
{
_startTime = value;
OnPropertyChanged("StartTime");
}
}
private long _timeElapsed;
public long TimeElapsed
{
get { return _timeElapsed; }
set
{
_timeElapsed = value;
OnPropertyChanged("TimeElapsed");
}
}
private bool _isClockAtZero;
public bool IsClockAtZero
{
get { return _isClockAtZero; }
set
{
_isClockAtZero = value;
OnPropertyChanged("IsClockAtZero");
}
}
private long _timeRemaining;
/// <summary>
/// time remaing in milliseconds from the timer Length
/// </summary>
public long TimeRemaining
{
get { return _timeRemaining; }
set
{
_timeRemaining = value;
OnPropertyChanged("TimeRemaining");
}
}
public StopwatchWrapper(long timeForClockInMilliseconds)
{
timer = new Timer(500);
timer.Elapsed += new ElapsedEventHandler(timer_Elapsed);
TimerLength = timeForClockInMilliseconds;
TimeRemaining = timeForClockInMilliseconds;
TimeElapsed = 0;
}
/// <summary>
/// dummy constructor for the xport of xml games
/// </summary>
public StopwatchWrapper()
{
}
void timer_Elapsed(object sender, ElapsedEventArgs e)
{
TimeSpan ts = DateTime.UtcNow - StartTime;
_millisecondsSinceLastInterval = (long)ts.TotalMilliseconds - _millisecondsSinceLastInterval;
TimeElapsed += _millisecondsSinceLastInterval;
TimeRemaining = _timerLength - TimeElapsed;
_millisecondsSinceLastInterval = (long)ts.TotalMilliseconds;
Console.WriteLine(TimeElapsed);
Console.WriteLine(_timerLength);
Console.WriteLine(TimeRemaining);
Console.WriteLine(StartTime);
IsRunning = true;
if (TimeRemaining <= 0)
IsClockAtZero = true;
}
public void Stop()
{
if (timer != null)
timer.Stop();
IsRunning = false;
}
public void Pause()
{
if (timer != null && IsRunning)
{
timer.Stop();
IsPaused = true;
}
}
public void Start()
{
StartTime = DateTime.UtcNow;
timer.Start();
IsRunning = true;
IsClockAtZero = false;
_millisecondsSinceLastInterval = 0;
}
/// <summary>
/// resumes the clock.
/// </summary>
public void Resume()
{
if (IsPaused)
{
StartTime = DateTime.UtcNow;
timer.Start();
IsRunning = true;
IsPaused = false;
_millisecondsSinceLastInterval = 0;
Console.WriteLine(TimeElapsed);
Console.WriteLine(_timerLength);
Console.WriteLine(TimeRemaining);
Console.WriteLine(StartTime);
}
}
/// <summary>
/// adds seconds to the clock.
/// </summary>
/// <param name="seconds">seconds to be added. Can be negative or positive.</param>
public void AddSecondsToClock(int seconds)
{
if (StartTime == new DateTime())
{
StartTime = DateTime.UtcNow;
TimeRemaining = _timerLength;
}
StartTime = StartTime.AddSeconds(seconds);
TimeRemaining += seconds * 1000;
TimerLength += seconds * 1000;
//Console.WriteLine("change");
//Console.WriteLine("change"+TimeRemaining);
//Console.WriteLine("change"+TimerLength);
}
/// <summary>
/// changes the amount of seconds of a clock
/// </summary>
/// <param name="seconds"></param>
public void changeSecondsOfClock(int seconds)
{
TimeElapsed = 0;
TimeRemaining = seconds * 1000;
TimerLength = seconds * 1000;
//Console.WriteLine("change");
//Console.WriteLine("change" + seconds);
//Console.WriteLine("change" + TimeRemaining);
//Console.WriteLine("change" + TimerLength);
}
public void Reset()
{
IsRunning = false;
StartTime = DateTime.UtcNow;
}
protected void OnPropertyChanged(string name)
{
PropertyChangedEventHandler handler = PropertyChanged;
if (handler != null)
{
handler(this, new PropertyChangedEventArgs(name));
}
}
}
I'd like to share a story of a sushi restaurant owner that I know. I was a bartender there, many, many years ago.
This restaurant owner came from Japan with his wife when they were in their twenties. They both spoke limited English and settled down in a part of New York that is predominantly Caucasian. For many years, he worked as a dishwasher while saving up diligently.
When he saved up enough money, he entered into a partnership with 2 others to open up a restaurant. One of the partners screwed the other two and he had to declare bankruptcy.
He went back to being a dishwasher, then later a cook, as he saved up money again. Finally, he had a chance to purchase a hole-in-the-wall restaurant that he thought he could improve. Unfortunately, that one also failed. And he declared bankruptcy for a second time.
That still didn't deter him. He worked again, saved up again, and opened up his third restaurant, a sushi restaurant. And for him, the third time was the charm.
This one became a success. It grew to 3 locations total. Every morning, he drove for hours to the fish market at 4am to select the best fish, then transported it to his restaurants in the back of his truck. He still has that truck. We all called it his "fishmobile" because it stunk of fish like you wouldn't believe.
He didn't reach this success until his 50s. Through it all, his wife was amazingly supportive. She worked alongside him in these restaurants too. They are retired now. He shared his story with me when I told him I was starting a business of my own.
I can't imagine having to lose so much, but in his perspective, he started out with nothing, so it wasn't that painful to return to nothing. I'm not saying I would want to do this with my wife and daughter, but hearing his story definitely gave me perspective.
The protection from snooping government for law abiders isn't for humdrum people like you. It's for people working to make the world better who come under fire through no illegal activity of their own.
Did you know the FBI put MLK under surveillance at the orders of Bobby Kennedy (then-Attorney General)? They didn't find evidence of crimes, so they threatened to publicize his extramarital affair if he didn't give up his civil rights work.
It's about preventing unchecked government power over those who aren't criminals who are working against the status quo.
OF COURSE you don't care if the NSA reads your email. You don't change anything, and subsequently don't matter.
We as a society care if the NSA reads the private emails of the next important up-and-coming political party leader who will break us out of the corporate-owned two-party system. THAT'S the person we're trying to protect, not boring uninspired people who "have nothing to hide".
Just a quick code sample on how to plug an Image Upload into C# and MVC. Since I searched all around the internet with no real easy example.
Put this somewhere on the page. This will be where the person adds the image. As you can see, we will be posting the image to the “data-action” attribute.
@Html.TextArea("Message", string.Empty, new
{
id = "wmd-input"
})
<div id="insertImageDialog" title="Insert Image">
<input type="file" name="file" id="file" data-action="/forum/postimageupload" />
</div>
Here is the Javascript.
- Below, you can see in the first block, I create another button for TinyMCE panel. I call it the imageUpload.
- I then add it to the Plugin Manager.
- I then enable it in the plugins: options called imageUpload.
- I create a Modal Dialog as I am using Jquery and the Jquery.UI library within my project.
- Below that is the hook up for the Image Upload Modal. As you can see I use the AjaxFileUpload by jquery.
$(function () {
tinymce.create('tinymce.plugins.imageUpload', {
createControl: function (n, cm) {
switch (n) {
case 'imageupload':
var c = cm.createButton('mysplitbutton', {
title: 'Upload Image',
image: '@Url.Content("~/content/images/icons/imageUpload.png")',
onclick: function () {
$dialog.dialog('open');
}
});
return c;
}
return null;
}
});
tinymce.PluginManager.add('imageIupload', tinymce.plugins.imageUpload);
tinymce.init({
mode: "textareas",
elements: "elm2",
theme: "advanced",
skin: "o2k7",
skin_variant: "silver",
plugins: "imageIupload,safari,style,layer,table,advhr,advimage,advlink,inlinepopups,preview,media,contextmenu,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template",
theme_advanced_buttons1: "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,outdent,indent,blockquote,|,formatselect,fontsizeselect",
theme_advanced_buttons2: "link,unlink,anchor,image,imageupload,cleanup,code,|,preview,|,forecolor,backcolor,|tablecontrols,|,hr,removeformat,visualaid,|,iespell,media,|,ltr,rtl",
theme_advanced_buttons3: "",
theme_advanced_buttons4: "",
theme_advanced_toolbar_location: "top",
theme_advanced_toolbar_align: "left",
theme_advanced_statusbar_location: "bottom",
theme_advanced_resizing: true,
language: "en",
relative_urls: false
});
var $dialog = $('#insertImageDialog').dialog({
autoOpen: true,
closeOnEscape: false,
modal: false,
open: function (event, ui) {
$(this).parent().css('position', 'fixed');
$(".ui-dialog-titlebar-close").hide();
}
});
var $loader = $('span.loading-small', $dialog);
var $url = $('input[type=text]', $dialog);
var $file = $('input[type=file]', $dialog);
var dialogInsertClick = function () {
dialogClose();
};
var dialogCancelClick = function () {
dialogClose();
};
var dialogClose = function () {
$url.val('');
$file.val('');
$dialog.dialog('close');
};
$dialog.dialog('option', 'buttons', {
'Insert': dialogInsertClick,
'Cancel': dialogCancelClick
});
var uploadStart = function () {
$loader.show();
};
var uploadComplete = function (response) {
$loader.hide();
if (response.success) {
tinyMCE.execCommand("mceInsertContent", false, "<img src='" + response.imagePath + "'/>");
dialogClose();
} else {
alert(response.message);
$file.val('');
}
};
$file.unbind('change').ajaxfileupload({
action: $file.attr('data-action'),
onStart: uploadStart,
onComplete: uploadComplete,
'params': {
'Id': '@Model.Id',
'TopicId': '@Model.Id'
},
});
$dialog.dialog('close');
});
Here is the MVC Model Method.
As you can see from above, within the AjaxFileUpload, I am posting a C# Model. Its called NewPost. Below is the Model I am passing in.
[HttpPost]
public ActionResult PostImageUpload(NewPost model)
{
string result;
var serializer = new JavaScriptSerializer();
try
{
// upload the file
if (model.File != null && model.File.ContentLength > 0)
{
}
}
catch (Exception exception)
{
ErrorDatabaseManager.AddException(exception, exception.GetType());
}
result = serializer.Serialize(
new { success = false, message = "Invalid image file" });
return Content(result);
}
Last but not least, I am posting a file within the Model. Rather than it be apart of the request object, its within the model.
public HttpPostedFileBase File { get; set; }
Hope this little write up helps someone.
Wikipedia just recently deleted the list of SMS Gateways page that I used on a regular basis. So I felt, its time to copy and paste since I still use it.
This is a list of carriers providing Short Message Service (SMS) transit via SMS gateways.
This list explains which email address to use if one wants to send an email and have it arrive as a text message on someone's phone. The number must contain no punctuation. For instance, to send to a number typically expressed in the United States as 987-555-0100, one would email 9875550100@SMS-gateway.
Some carriers have multiple gateways. The SMS gateway refers to Short Message Services which are capable of transmitting plain text messages only. MMS refers to "Multimedia Messaging Services" which are generally capable of carrying messages which include text, pictures and audio.
SMS-to-mail gateway |
All Carrier | International | number@email.experttexting.com | Free Registration Required - www.ExpertTexting.com | | N/A |
Aircel | India | number@aircel.co.in | Not working for some reason | | |
Airtel | India | number@airtelap.com | Not working for some reason | | |
Airtel | Karnataka, India | number@airtelkk.com | Not working for some reason | | |
Ahra Samaneh Iranian Co. ( اهرا سامانه ایرانیان ) | Iran | (missing?) | [1] | | |
AirFire Mobile | United States | number@sms.airfiremobile.com | [2] | | |
Aio Wireless | United States | number@mms.aiowireless.net | [3] | | |
Alaska Communications | United States | number@msg.acsalaska.com | [4] | | |
Aliant | Canada | number@sms.wirefree.informe.ca | | | |
Alltel (Allied Wireless) | United States | number@sms.alltelwireless.com (SMS) number@mms.alltelwireless.com (MMS) | | | |
Verizon Wireless (merger with Alltel was completed in November 2009)[1] | United States | number@message.Alltel.com[2] (SMS & MMS) number@text.wireless.alltel.com (SMS) number@mms.alltel.net (MMS) number@vtext.com (SMS) | [5] | | |
Altiria | Spain | info@altiria.com[3] | SMS masivo | | |
Ameritech | United States | number@paging.acswireless.com | [6] | | |
Amitas Digital | Australia | | Requires Login [7] | | |
Anchor Mobile | United States | | [8] | | |
Andhra Pradesh AirTel | India | 91number@airtelap.com | [9] | | |
Andhra Pradesh Idea Cellular | India | number@ideacellular.net | [10] | | |
Api4SMS | Austria | number@members.api4sms.net | Requires Login SMS Gateway | | |
aql | United Kingdom | number@text.aql.com[4] | [11] | 44 7766 40 41 42 | address text |
SourceSMS | United Kingdom | | [12] | address text | |
Assurance Wireless | United States | number@vmobl.com | | | |
AT&T Mobility | United States | domestic-number@txt.att.net (SMS), domestic-number@mms.att.net (MMS) (Note: This gateway fails to handle complete phone numbers; the country code must be omitted, leaving only the ten-digit NANP number.)[5] | Requires login[6] | 121 111[7] | address text address (subject) text |
AT&T grandfathered customers (originally AT&T, then Cingular, now AT&T Mobility). Officially offline since June 10, 2010, under AT&T ticket CM20100610_10186966. | United States | number@mmode.com | | 121 | address text |
AT&T Mobility (formerly Cingular) | United States | number@mms.att.net number@txt.att.net number@cingularme.com number@mobile.mycingular.com | | | |
AT&T Enterprise Paging | United States | number@page.att.net | | | |
AT&T Global Smart Messaging Suite - Powered By Soprano | United States | number@sms.smartmessagingsuite.com | [8] | | |
B2Bsms B2B SMS | India | info@b2bsms.co.in or info@b2bsms.co.in | [13] | | |
Beeline (Russia) | Russia | number@sms.beemail.ru | | | |
Bell Mobility & Solo Mobile | Canada | number@txt.bell.ca or number@txt.bellmobility.ca or 10digitnumber@txt.northerntelmobility.com | [14] | | |
BellSouth | United States | number@bellsouth.cl | [15] | | |
blablaSMS | International | | [16] | | |
Bluegrass Cellular | United States | number@sms.bluecell.com (SMS) number@mms.myblueworks.com (MMS) | [17] | | |
Bluesky Communications | American Samoa, United States | number@psms.bluesky.as | | | |
Boost Mobile | United States | number@sms.myboostmobile.com (SMS) number@myboostmobile.com (MMS)[9] | | |
Strata | United States | number@rinasms.com (SMS) | | |
Bouygues Telecom (company) | France | number@mms.bouyguestelecom.fr | | | |
Box Internet Services SMS Gateway | Switzerland | number@sms.boxis.net (SMS) number@mms.boxis.net (MMS) | SMS Gateway + SMS API [10] | | |
SFR | France | number@sfr.fr | | | |
BudgetSMS.net | International | | Requires Login SMS Gateway | | |
BulkSMS.com | International | number@bulksms.net | Requires Login SMS Gateway API | | |
Bulletin.net | International | InternationalFormattednumber@bulletinmessenger.net | Requires Login [18] | | |
C Beyond (All Page Wireless) | | number@cbeyond.sprintpcs.com | | | |
Cellcom | United States | number@cellcom.quiktxt.com | | | |
Cellular South | United States | number@csouth1.com | | | |
Centennial Wireless | United States, Puerto Rico, and the U.S. Virgin Islands (merging with AT&T Mobility) | number@cwemail.com | [19] | | | |
Cequens | Middle East And Africa | www.cequens.com | Requires signup at http://www.cequens.com | | | |
Chariton Valley Wireless | United States | number@sms.cvalley.net | | | |
Chat Mobility | United States | number@mail.msgsender.com | | | |
Chennai Skycell / Airtel | India | 919840number@airtelchennai.com | [20] | | |
Chennai RPG Cellular | India | 9841number@rpgmail.net | [21] | | |
China Mobile | China | number@139.com | | | |
Cincinnati Bell | Cincinnati, Ohio, United States | number@gocbw.com (SMS) number@mms.gocbw.com (MMS) | | | |
Cingular (Postpaid) | United States | number@cingular.com number@mobile.mycingular.com | [22] (must be logged in prior to visiting this link) | | |
Claro | Brazil | number@clarotorpedo.com.br | [23] (registration not required) | | |
Claro | Nicaragua | number@ideasclaro-ca.com | [24] | | |
Claro | Peru | | [25] | | |
Claro | Puerto Rico | number@vtexto.com | [26] | | |
Cleartalk | United States | number@sms.cleartalk.us | [27] | | |
Claro | Colombia | number@iclaro.com.co | [28] | | |
Connection Software (CSoft) | United Kingdom | number@itsarrived.net | [29] | |
Consumer Cellular | United States | number@cingularme.com | [30] | | Subject and Body are concatenated into the text message |
Cricket | United States | number@mms.mycricket.com (SMS and MMS) | [31] | | (note: Cricket does not allow SMS messages to be sent to phone. All messages are MMS) |
C Spire Wireless | United States | number@cspire1.com | [32] | | |
Accessyou | Hong Kong | number@messaging.accessyou.com (MMS) | [33] | | |
CSL | Hong Kong | number@mgw.mmsc1.hkcsl.com (MMS) | [34] | | |
CTI Móvil (Now Claro) | Argentina | number@sms.ctimovil.com.ar | [35] | | |
CTI Móvil (Now Claro) | Paraguay | | [36] | | |
CTI Móvil (Now Claro) | Uruguay | | [37] | | |
Delhi Airtel | India | 919810number@airtelmail.com | [38] | | |
Digicel (Dominica) | Dominica | (no-area-code)number@digitextdm.com | [39] | | |
DTC | United States | number@sms.advantagecell.net | | | |
E-Plus | Germany | 0number@smsmail.eplus.de | [40] | | |
Edge Wireless | United States | number@sms.edgewireless.com | [41] | | |
Element Mobile | United States | number@SMS.elementmobile.net | | | |
Emtel | Mauritius | number@emtelworld.net | [42] | | |
Esendex | United Kingdom | number@echoemail.net | [43] | | |
Esendex | Australia | number@echoemail.net | [44] | | |
Esendex | United States | number@echoemail.net | [45] | | |
Esendex | Spain | number@esendex.net | [46] | | |
Eventis | Moldova | | [47] | | |
FreeSMSGateway.com | United States | | [48] | | |
Fido | Canada | number@sms.fido.ca (as of June 2012) | [49] ( Rogers' Web server is faster ) | | |
Firmensms | Austria | 0043number@subdomain.firmensms.at | Requires Login SMS Gateway | | |
Freebie SMS | Europe | number@smssturen.com | [50] ( Message in subject line ) | | |
General Communications Inc. | Alaska, United States | number@mobile.gci.net | [51] | | |
Globalstar (satellite) | International | number@msg.globalstarusa.com or number@g2smsc.globalstar.com | [52][53] | | |
Globul | Bulgaria | 35989number@sms.globul.bg | [54] | | |
Goa Airtel | India | 919890number@airtelmail.com | [55] | | |
Goa Idea Cellular | India | number@ideacellular.net | [56] | | |
Golden State Cellular | California, United States | number@gscsms.com | [57] | | |
Greatcall | California, United States | number@vtxt.com | [58] | | |
Gujarat Idea Cellular | India | number@ideacellular.net | [59] | | |
Gujarat Airtel | India | 919898number@airtelmail.com | [60] | | |
Gujarat Celforce / Fascel | India | 9825number@celforce.com | [61] | | |
Guyana Telephone & Telegraph | Guyana | number@sms.cellinkgy.com | [62] | | |
Haryana Airtel | India | 919896number@airtelmail.com | [63] | | |
Haryana Escotel | India | 9812number@escotelmobile.com | [64] | | |
Hawaiian Telcom Wireless | Hawaii, United States | number@hawaii.sprintpcs.com | | | |
HSL Mobile | United Kingdom | number@sms.haysystems.com[11] | [65] | | |
Helio | South Korea and United States | number@myhelio.com | | | |
Himachai Pradesh Airtel | India | 919816number@airtelmail.com | | | |
ICE | Costa Rica | number@sms.ice.cr | | 1001 | address : (subject) text |
Illinois Valley Cellular | United States | number@ivctext.com (SMS) number@ivcdata.com (MMS) | [66] |
Iridium (satellite) | International | number@msg.iridium.com[12] | [67] | | |
i wireless (T-Mobile) | Midwest, United States | number.iws@iwspcs.net | [68] | | |
i-wireless (Sprint PCS) | United States | number@iwirelesshometext.com | [69] | | |
Kajeet | United States | number@mobile.kajeet.net | | | |
Karnataka Airtel | India | 919845number@airtelkk.com | [70] | | |
Kerala Airtel | India | 919895number@airtelkerala.com | [71] | | |
Kerala Escotel | India | 9847number@escotelmobile.com | [72] | | |
Kolkata Airtel | India | 919831number@airtelkol.com | [73] | | |
Koodo Mobile | Canada | number@msg.telus.com | [74] | | |
LongLines | United States | number@text.longlines.com | [75] | | |
Lynx Mobility | Canada | number@sms.lynxmobility.com | [76] | | |
M1 | Singapore | number@m1.com.sg | [77] | | |
Madhya Pradesh Airtel | India | 919893number@airtelmail.com | [78] | | |
Maharashtra Airtel | India | 919890number@airtelmail.com | [79] | | |
Maharashtra Idea Cellular | India | number@ideacellular.net | [80] | | |
Más Móvil | Panama | number@cwmovil.com | [81] | | |
Mediaburst | United Kingdom | number@sms.mediaburst.co.uk | [82] | | |
Ncell(Previously Mero Mobile)[13] | Nepal | 977number@sms.ncell.com.np (Requires registration) | [83] | | |
Meteor | Ireland | number@sms.mymeteor.ie (SMS) (Not currently valid) number@mms.mymeteor.ie (MMS) (No longer working : (Sender not allowed error) | [84] | | |
MetroPCS | United States | number@mymetropcs.com | | | |
Moldcell | Moldova | | [85] | | |
Mobiltel | Bulgaria | 35988number@sms.mtel.net | [86] | | |
Mobitel | Sri Lanka | number@sms.mobitel.lk | [87] Mobitel no longer offers email2sms. | | |
textit.biz | Sri Lanka | http://textit.biz/sendmsg/?ph=xxxx&tx=xxxxx | [88] | | |
Movistar | Argentina | number@sms.movistar.net.ar | [89] | | |
Movistar | Colombia | number@movistar.com.co | [90] | | |
Movistar | Spain | 0number@movistar.net | [91] | | |
Movistar | Spain and Latin America | number@movimensaje.com.ar | | | |
Movistar | Uruguay | 95number@sms.movistar.com.uy | | | |
MTN | South Africa | number@sms.co.za | [92] | | |
MTS Mobility | Canada | number@text.mtsmobility.com | [93] | | |
Mumbai Airtel | India | 919892number@airtelmail.com | [94] | | |
mVaayoo.com | India | http://www.mvaayoo.com/SMSGateway.html | Requires Registration[14] | | |
My-Cool-SMS | United Kingdom | number@my-cool-sms.com | [95] | | |
Nepal Telecom | Nepal | | [96] | | |
Nextech | United States | number@sms.ntwls.net | [97] | | |
Nextel | Mexico | number@msgnextel.com.mx | [98] | | |
Nextel | Argentina | TwoWay.11number@nextel.net.ar | [99] | | |
O2 | Germany | 0number@o2online.de | [100] | | |
OgVodafone | Iceland | number@sms.is | [101] | | |
Orange Moldova | Moldova | | [102] | | |
Orange | Netherlands | 0number@sms.orange.nl | no dns for sms.orange.nl [103] | | |
Orange | Switzerland | | [104] | | |
Orange | United Kingdom | number@orange.net | [105] | | |
Oxygen8 | United Kingdom | http://www.oxygen8.com | Requires Login SMS Gateway | | |
Page Plus Cellular (Verizon MVNO) | United States | number@vtext.com (SMS) number@vzwpix.com (MMS) number@mypixmessages.com (MMS) | [106] [107] | | |
Panacea Mobile | Worldwide | number@api.panaceamobile.com (SMS) | [108] (requires login) | | subject: username password body: the message |
Pioneer Cellular | United States | nine-digit-number@zsend.com | | | |
Personal | Argentina | number@alertas.personal.com.ar (call for activation) | [109][15] | | |
Plus | Poland | +number@text.plusgsm.pl (+48domestic-number@text.plusgsm.pl) | [110] | | |
Pocket Wireless | Texas, United States | number@sms.pocket.com | | | |
PC Telecom | Canada | number@mobiletxt.ca | | | |
Punjab Airtel | India | 919815number@airtelmail.com | [111] | | |
Qwest Wireless | United States | number@qwestmp.com | [112] | | |
Red Pocket Mobile (AT&T MVNO) | United States | number@txt.att.net (SMS) number@mms.att.net (MMS) | | | |
Rogers Wireless | Canada and United Stateslog | number@sms.rogers.com or 1number@mms.rogers.com | Requires Login[16] | | Name (subject) text (Note: Subject must be in plain text, not Q-encoded as described in RFC 2047.) |
RoutoMessaging | Worldwide | number@email2sms.routomessaging.com | [113] | | Subject: Sender ID (Originating Address who is sending the message) Body: the message (Note: plain text emails supported) |
SaskTel | Canada | number@sms.sasktel.com number@pcs.sasktelmobility.com | [114] | | |
Sendega | Norway | number@sendega.com (registration required) | [115] | | Content support: subject, body or subject + body. Settings available from website (login required) |
Setar Mobile email (Aruba) | Aruba | number@mas.aw (297domestic-number@mas.aw) | [116] | | |
Síminn | Iceland | number@box.is | [117] | | |
Simple Mobile | United States | number@smtext.com | [118] | | |
SMS Broadcast | Australia | number@send.smsbroadcast.com.au | Requires Login [119] | | |
SMS Global | Australia | number@email.smsglobal.com | Requires Login [120] | | |
SMS Central | Australia | number@sms.smscentral.com.au | Requires Login [121] | | |
SMS4Free | United States | | [122] | | |
SMSPUP | Australia | domestic-number@smspup.com | Requires Login [123] | | |
Starhub Enterprise Messaging Solution (powered by Soprano) | Singapore | number@starhub-enterprisemessaging.com(sms@starhub-enterprisemessaging.com ) | [124] | | |
Southernlinc | United States | number@page.southernlinc.com (SMS) | | | |
South Central Communications | United States | number@rinasms.com (SMS) | [125] | | |
Spikko | Israel | number@SpikkoSMS.com | [126] | | |
Sprint | United States | number@messaging.sprintpcs.com (SMS) number@pm.sprint.com (MMS) --> No Longer valid as Sprint no longer supports MMS via email to phone. | [127] requires login | 6245 | address message |
Straight Talk | United States | number@vtext.com (SMS) number@txt.att.net (SMS if using the AT&T SIM) number@tmomail.net (MMS or SMS when using the T-Mobile SIM, begin 'number' with 1 then phone number) number@mypixmessages.com (MMS) number@mms.att.net (MMS & SMS) number@mmst5.tracfone.com (T-Mobile SIM MMS & SMS) number@messaging.sprintpcs.com (SMS) number@tracfone.plspictures.com (MMS) | | | |
Solavei | United States | XXXYYYZZZZ@tmomail.net (MMS or SMS) --Uses T-mobile's gateway -- number is the 10 cell number or can include 1 at the beginning. | [128] | 500[17] | address text address/subject/text address#subject#text |
Sunrise Communications | Switzerland | number@gsm.sunrise.ch | [129] (registration required) | | |
Swisscom | Switzerland | | [130] [131] [132] | | |
Syringa Wireless | United States | number@rinasms.com | | | |
TeletopiaSMS | Norway | number@sms.teletopiasms.no (registration required) | [133] | | Content settings available from website |
T-Mobile | United States | number@tmomail.net (MMS or SMS) --number can and by default properly begins with "1" (the US country code) | [134] | 500[17] | address text address/subject/text address#subject#text |
T-Mobile (Optus Zoo) | Australia | 0number@optusmobile.com.au | Requires Login[18] | | |
T-Mobile | Austria | number@sms.t-mobile.at (43676domestic-number@sms.t-mobile.at) | [135] | | |
T-Mobile | Croatia | number@sms.t-mobile.hr (385domestic-number@sms.t-mobile.hr) | [136] | 100 | address##subject#text |
T-Mobile | Germany | number@t-mobile-sms.de | [137] | | |
T-Mobile | Netherlands | 31number@gin.nl | [138] | | |
Tamil Nadu Airtel | India | 919894number@airtelmobile.com | [139] | | |
Tamil Nadu Aircel | India | 9842number@airsms.com | [140] | | |
Tele2 | Sweden | 0number@sms.tele2.se | [141] | | |
Telecom New Zealand | New Zealand | number@etxt.co.nz | [142] | | |
Teleflip | United States | number@teleflip.com | [143] | | |
Telekom Srbija | Serbia | | [144] | | |
Telstra Integrated Messaging (powered by Soprano) | Australia | sms@tim.telstra.com(mobile@sms.tim.telstra.com) | Requires Login[19] | | |
All Australian Mobile Networks | Australia | number@sms.itcompany.com.au | Requires Login[20] | | |
Telus Mobility | Canada and United States | number@msg.telus.com (SMS) number@mms.telusmobility.com (MMS) | [145] | | |
TellusTalk | Europe | number@esms.nu | [146] | | |
TextOver | United Kingdom | Log into TextOver for details | [147] | | |
TextAnywhere | United Kingdom | | [148] | | |
Thuraya (satellite) | International | | [149] | | |
Tigo (Formerly Ola) | Colombia | number@sms.tigo.com.co | [150] | | |
TIM | Italy | 0number@timnet.com | [151] | | |
Ting | United States | number@message.ting.com (SMS) No MMS Gateway | | | |
TracFone (prepaid) | United States, Puerto Rico, and the U.S. Virgin Islands | direct: number@mmst5.tracfone.com indirect: number@txt.att.net number@tmomail.net number@vtext.com number@email.uscc.net number@message.alltel.com
| | | |
Txtlocal | United Kingdom | number@txtlocal.co.uk | [152] | | |
Telcel | Mexico | number@itelcel.com | [153] | | |
UkraineCalling | International | | [154] | | |
Unicel | United States | number@utext.com | [155] | | |
UniMóvil Corporation | United Kingdom | number@viawebsms.com | [156] | |
Union Wireless | United States | number@union-tel.com | [157] |
Unité | Moldova | | [158] | | |
US Cellular | United States | number@email.uscc.net (SMS) number@mms.uscc.net (MMS) | [159] | | |
USA Mobility | United States | number@usamobility.net (SMS) | [160] | | |
UTBox | Australia | number@sms.utbox.net | Requires Login[21] | | |
Uttar Pradesh West Escotel | India | 9837number@escotelmobile.com | [161] | | |
Verizon Wireless | United States | number@vtext.com (SMS) number@vzwpix.com (MMS) | [162] | 6245 | address (subject) text |
Viaero | United States | number@viaerosms.com (SMS) number@mmsviaero.com (MMS) | [163] | | |
Vivo | Brazil | number@torpedoemail.com.br | [164] (registration required) | | |
Virgin Mobile | Canada | number@vmobile.ca | | 6245 | address message |
Virgin Mobile | United States | number@vmobl.com (SMS)[22] number@vmpix.com (MMS)[23] | | 6245 | address message |
Virgin Mobile | United Kingdom | number@vxtras.com | Does not appear to work[18] | | |
Vodacom | South Africa | number@voda.co.za | [165] (registration required) | | |
Vodafone | Czech Republic | alias@vodafonemail.cz (registration required in Samoobsluhy) | | | |
Vodafone | Germany | 0number@vodafone-sms.de | [166] | | |
Vodafone | Italy | 3**number@sms.vodafone.it | | | |
Vodafone | Portugal | | [167] (registration required) | | |
Vodafone | Spain | 0number@vodafone.es | [168] | | |
Vodafone | New Zealand | number@mtxt.co.nz | [169] | | |
Voyager Mobile | United States | number@text.voyagermobile.com | | | |
West Central Wireless | United States | number@sms.wcc.net | [170] | | |
Wind Mobile | Canada | number@txt.windmobile.ca | | 4000[24] | address text |
www.srisms.in | INDIA | PC / Online Based Text Messaging | BULK SMS GATEWAY AND API FOR DEVELOPER | N/A | PC / Online Based Text Messaging / Android App |
24x.com | UK | Easy web screen, Email to sms or API's for programmers - This is a business only charged for service | www.24x.com | Business SMS only, use screens, email or API's | [171] Easy Programmer's Manual with example code for cutting and pasting into your applications. |
SendSMS.pk | Pakistan | Complete Developer API | SendSMS.pk | Just reply to the number from which you receive the SMS | web based sms, 2 ways sms, and api |
SMSPinoy.com | Philippines | Complete Developer API | SMSPinoy.com | Just reply to the number from which you receive the SMS | web based sms, 2 ways sms, and api |
smsthing.com | United Kingdom | Free Gateway, Replyable | smsthing.com | Reply to received messages | Send from web, email, receive free with api |
BIPKampany.hu | Hungary | Web-to-SMS, email-to-sms or API's for programmers | sms.bipkampany.hu | SMS gateway/API for two way messaging, email-to-SMS | SMS gateway/API manual for software integration, PHP examples |
Eurobate.no | Norway, Denmark, Sweden | | List all services | Customized | Full standalone, and integrated solutions. |
Msg2Send | Singapore | Web Based | Msg2Send | N/A | |
streetunity.org/sms | United Kingdom | Free from web only | streetunity.org/sms | N/A | Reply to SMS received to email the sender |
CoolSMS SMS Gateway | Denmark | sms<number>@coolsmsc.dk[25] | www.coolsms.com | Short code or MSISDN | Received SMS are sent to the user via smtp, smpp or HTTP |
Kapow SMS Gateway | United Kingdom | <number>@kapow.co.uk[25] | www.kapow.co.uk | Short code or MSISDN | Received SMS are sent to the user via email or HTTP |
www.fastsms.co.uk | United Kingdom | PC / Online Based Text Messaging | www.fastsms.co.uk | N/A | PC / Online Based Text Messaging |
XIT Communications | Texas, United States | number@sms.xit.net | [172] | | |
Polkomtel | Poland | +48number@text.plusgsm.pl | [173] | | |
Papersky | United Kingdom | PC / Online Based Text Messaging | www.papersky.com | N/A | PC / Online Based Text Messaging |
A few software libraries and resources have cropped up that utilize the gateways in the list for application software development purposes.
References[edit]
External links[edit]
I kept running into two error messages. My iOS Hello world app wasn’t starting up. Just a simple app after the host machine was synced and built. So kept looking for solutions until I found one here: http://forums.xamarin.com/discussion/5217/communication-issues-from-windows-8-to-mac-mini
Here are the two messages I was running into:
- There was an error launching the application: iOS Simulator failed to install the application.
- has exited with code 0 or has exited with code –1
The solution was of two parts. I had to reset the iPhone Simulator and add the identifier information in. Once done, it seemed to work the proper way.
On iOS
Click iPhone Simulator a the top title bar, then Reset Content and Settings.
Hope that helps for someone.
We are all aware of the problems with the new roll out of the healthcare.gov website. The large amount of JS files being sent back and forth, the slow down and the inability to sign up at most hours of the day. But thats not what worries me.
What worries me is if this thing was so POORLY designed on the UI side, what do you think it look like on the back end side? Do you actually think they offer encryption, data protection and have taken the time to implement industry standards to protect our most important information?
Seeing that the front end is soo poorly designed, I don't really have any faith in the back end. This is what the news should be wondering, questioning and even guessing.
What say you? Do you believe they did good on the back end?
Please don't bring Politics into this. Its a purely technical talk.