Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: #2679 - DataFrame.to_html() urls_as_links parameter. #10294

Closed
wants to merge 1 commit into from

Conversation

lexual
Copy link
Contributor

@lexual lexual commented Jun 6, 2015

New urls_as_links boolean paramater that will output urls as href html
links. ref #2679

Thanks for @tdas14 for initial code.

New urls_as_links boolean paramater that will output urls as href html
links. ref pandas-dev#2679
@sinhrks sinhrks added Output-Formatting __repr__ of pandas objects, to_string IO HTML read_html, to_html, Styler.apply, Styler.applymap labels Jun 6, 2015
@jreback jreback added this to the 0.17.0 milestone Jul 28, 2015
@jreback
Copy link
Contributor

jreback commented Jul 28, 2015

@TomAugspurger (I recall you doing some work on conditional html formatting, though orthogonal to this affect API)

@jreback
Copy link
Contributor

jreback commented Jul 28, 2015

@lexual can you rebase

@jreback
Copy link
Contributor

jreback commented Aug 26, 2015

@lexual can you rebase / update

@jreback jreback modified the milestones: Next Major Release, 0.17.0 Aug 26, 2015
@jreback
Copy link
Contributor

jreback commented Oct 11, 2015

pls see comments on #9880

@jreback
Copy link
Contributor

jreback commented Oct 11, 2015

IOW this needs to have a global option (that defaults to False)

@jreback
Copy link
Contributor

jreback commented Nov 2, 2015

closing, but if you would like to continue working on this pls reopen

@jreback jreback closed this Nov 2, 2015
@lexual
Copy link
Contributor Author

lexual commented Nov 12, 2015

I have rebased, but don't have permissions to re-open I believe.

Please advise next steps to get it merged.

Apologies for long absence ;)

@lexual
Copy link
Contributor Author

lexual commented Nov 12, 2015

lexual@49992e9

rebase @jreback

@jreback
Copy link
Contributor

jreback commented Nov 12, 2015

@lexual this is more appropriate as a method in df.style for #10250

e.g.

df.style.show_urls_as_links() or something. You want to do a PR against @TomAugspurger branch for that?

And the idea is that a style can be created that can be .set as a style (or a default), so you can simply 'use' a style as the default and build on it.

@TomAugspurger
Copy link
Contributor

@lexual let me know if you want to do that PR agains my branch in #10250, it will actually be quite simple thanks to jinja.

Right now in the Jinja template I've got a check for if the value is a number or not. Jinja has a urlize filter that you can apply to the else block.

We will need a more general way of applying arbitrary tags / modify the template, but that could work for now.

@lexual
Copy link
Contributor Author

lexual commented Nov 14, 2015

@TomAugspurger yep, I'll try to take a look when I get a chance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO HTML read_html, to_html, Styler.apply, Styler.applymap Output-Formatting __repr__ of pandas objects, to_string
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants