# Create new topic by pasting fails when URL is too long

**URL:** https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352
**Category:** Bug
**Created:** [March 17, 2017, 1:52pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352 "2017-03-17T13:52:45Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![SidV](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidv/32/119460_2.png) [@SidV](https://meta.discourse.org/u/SidV)
#### Post date: [March 17, 2017, 1:52pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/1 "2017-03-17T13:52:45Z")

</div>

Hello!

I have a problem with new feature that creates new topic when a user directly paste a URL in title section.

Example (on [try.discourse.org](http://try.discourse.org))

 ![](https://global.discourse-cdn.com/meta/original/3X/6/a/6a3e33812d2febdf16cd49f0b7b5a852d674c7b3.png)

As you can see, the “url” before the edited title appears truncated because are a “limit” to title.  
So, if the URL exceeds that limit, does not paste correct URL.

For this example I used: `https://blog.discourse.org/2017/03/moving-from-facebook-groups-to-discourse/more-text-to-url-more1-more2-more3-more4-more5-more6-more7-8-9-10-11-12-13-14-15-16`,

I know this URL does not exist. But I did not know the URL limit for [try.discourse.org](http://try.discourse.org) site. 😛

I hope you can understand me.

I need to know how to fix the problem, and edit the new topic.

I mean, when a user creates a new topic from one URL, the link informed below the title, how edit that link?

---

<div class="post-metadata">

### Author: ![elijah](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/elijah/32/104055_2.png) [@elijah](https://meta.discourse.org/u/elijah)
#### Post date: [March 17, 2017, 6:45pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/2 "2017-03-17T18:45:51Z")

</div>

> [@SidV](#):
>
> I hope you can understand me.

Let me restate to make sure it is clear:

Very long URLs used to create a post in Reddit style get wrongly clipped to the length of the title size limit without warning or error messages.

---

<div class="post-metadata">

### Author: ![SidV](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sidv/32/119460_2.png) [@SidV](https://meta.discourse.org/u/SidV)
#### Post date: [March 18, 2017, 12:20am UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/3 "2017-03-18T00:20:51Z")

</div>

> [@elijah](#):
>
> Very long URLs used to create a post in Reddit style get wrongly clipped to the length of the title size limit without warning or error messages.

Exactly.  
And, you (as admin or staff member) cant edit the url clipped. 😢

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [March 18, 2017, 3:29am UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/4 "2017-03-18T03:29:45Z")

</div>

Sure we should fix this next week @neil

---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [May 18, 2017, 5:44pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/5 "2017-05-18T17:44:27Z")

</div>

Fixed.

If pasting links is allowed, the title field will allow you to enter a string that’s too long. After oneboxing completes, the title input will be replaced with the title of the input as usual. You can then edit the title so it isn’t too long.

---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [May 18, 2017, 5:44pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/6 "2017-05-18T17:44:31Z")

</div>



---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [May 19, 2017, 3:13pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/7 "2017-05-19T15:13:27Z")

</div>



---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [May 19, 2017, 3:44pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/8 "2017-05-19T15:44:39Z")

</div>

It’s something related to this topic too [Paste links if you have short topic title length](https://meta.discourse.org/t/paste-links-if-you-have-short-topic-title-length/60024) and I think the cause is the site settings `max topic title length` (set to 60)

I’ve upgrade discourse to beta 12 some days ago and I see that the link in the title works even if it’s very long as @neil said .  
Btw in the message, the link is truncated. This is not a real bug because in the preview (or if you save the message) the onebox works fine as you can see here [https://forum.adunanza.net/t/l-ex-boss-di-automator-in-apple-annuncia-la-cmd-d/13471](https://forum.adunanza.net/t/l-ex-boss-di-automator-in-apple-annuncia-la-cmd-d/13471) but I do not think it is a correct behavior.

After saving the post I have reopened it and I see that the link remains truncated as you can see here [https://forum.adunanza.net/raw/13471](https://forum.adunanza.net/raw/13471)

`http://www.macitynet.it/lex-responsabile-sistemi-automazione`  
instead of  
`http://www.macitynet.it/lex-responsabile-sistemi-automazione-apple-annunciato-la-cmd-d-conference/`)

What do you think?

---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [May 19, 2017, 3:53pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/9 "2017-05-19T15:53:15Z")

</div>

> [@Trash](#):
>
> I’ve upgrade discourse to beta 12 some days ago

I can’t reproduce this, and the fix was only 22 hours ago so I don’t think you have the fix.

With max title length of 40:

 ![](https://global.discourse-cdn.com/meta/original/3X/f/5/f5e6be4823a2116ac5b21213b062483c78c3ebb0.png)

---

<div class="post-metadata">

### Author: ![dax](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dax/32/244677_2.png) [@dax](https://meta.discourse.org/u/dax)
#### Post date: [May 19, 2017, 3:55pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/10 "2017-05-19T15:55:58Z")

</div>

> [@neil](#):
>
> the fix was only 22 hours ago so I don’t think you have the fix.

Surely I don’t even this fix yet. I’ll upgrade the site tomorrow morning to see the fix in action, thanks!

---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [May 19, 2017, 3:56pm UTC](https://meta.discourse.org/t/create-new-topic-by-pasting-fails-when-url-is-too-long/59352/11 "2017-05-19T15:56:35Z")

</div>


